From: Brion Vibber Date: Tue, 19 Jun 2007 16:00:11 +0000 (+0000) Subject: * (bug 10309) Initialise parser state properly in extractSections(), fixes X-Git-Tag: 1.31.0-rc.0~52496 X-Git-Url: http://git.cyclocoop.org/url?a=commitdiff_plain;h=7fe0850db1db0a906a193db97655ee775389e760;p=lhc%2Fweb%2Fwiklou.git * (bug 10309) Initialise parser state properly in extractSections(), fixes some cases where section edits broke because tags were improperly stripped --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index cc97ddb038..f500a3006b 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -177,6 +177,9 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN Signature dates for Japanese and other languages including weekday now show the correct day to match the rest of the time in local time. * Escape the output of magic variables that return page name or part of it +* (bug 10309) Initialise parser state properly in extractSections(), fixes + some cases where section edits broke because tags were improperly stripped + == API changes since 1.10 == diff --git a/includes/Parser.php b/includes/Parser.php index 20d8e936cb..2793645342 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -4609,6 +4609,10 @@ class Parser * for "replace", the whole page with the section replaced. */ private function extractSections( $text, $section, $mode, $newtext='' ) { + # I.... _hope_ this is right. + # Otherwise, sometimes we don't have things initialized properly. + $this->clearState(); + # strip NOWIKI etc. to avoid confusion (true-parameter causes HTML # comments to be stripped as well) $stripState = new StripState;