From d9022f63880ce039446fba8364f68e656b7bf4cb Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Thu, 3 May 2012 13:01:35 +0200 Subject: Update to MediaWiki 1.19.0 --- includes/parser/Preprocessor_DOM.php | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'includes/parser/Preprocessor_DOM.php') diff --git a/includes/parser/Preprocessor_DOM.php b/includes/parser/Preprocessor_DOM.php index 755563a0..066589f6 100644 --- a/includes/parser/Preprocessor_DOM.php +++ b/includes/parser/Preprocessor_DOM.php @@ -81,7 +81,7 @@ class Preprocessor_DOM implements Preprocessor { */ function memCheck() { if ( $this->memoryLimit === false ) { - return; + return true; } $usage = memory_get_usage(); if ( $usage > $this->memoryLimit * 0.9 ) { @@ -543,7 +543,7 @@ class Preprocessor_DOM implements Preprocessor { 'open' => $curChar, 'close' => $rule['end'], 'count' => $count, - 'lineStart' => ($i == 0 || $text[$i-1] == "\n"), + 'lineStart' => ($i > 0 && $text[$i-1] == "\n"), ); $stack->push( $piece ); @@ -957,8 +957,7 @@ class PPFrame_DOM implements PPFrame { return $root; } - if ( ++$this->parser->mPPNodeCount > $this->parser->mOptions->getMaxPPNodeCount() ) - { + if ( ++$this->parser->mPPNodeCount > $this->parser->mOptions->getMaxPPNodeCount() ) { return 'Node-count limit exceeded'; } @@ -1340,6 +1339,15 @@ class PPFrame_DOM implements PPFrame { function isTemplate() { return false; } + + /** + * Get a title of frame + * + * @return Title + */ + function getTitle() { + return $this->title; + } } /** -- cgit v1.2.3-54-g00ecf