http://www.mediawiki.org/wiki/Special:Code/MediaWiki/93763

Revision: 93763
Author:   reedy
Date:     2011-08-02 16:18:10 +0000 (Tue, 02 Aug 2011)
Log Message:
-----------
Revert r93688 per Platonides

Modified Paths:
--------------
    branches/wmf/1.17wmf1/includes/parser/Preprocessor_DOM.php
    trunk/phase3/includes/parser/Preprocessor_DOM.php

Modified: branches/wmf/1.17wmf1/includes/parser/Preprocessor_DOM.php
===================================================================
--- branches/wmf/1.17wmf1/includes/parser/Preprocessor_DOM.php  2011-08-02 
16:04:36 UTC (rev 93762)
+++ branches/wmf/1.17wmf1/includes/parser/Preprocessor_DOM.php  2011-08-02 
16:18:10 UTC (rev 93763)
@@ -902,12 +902,12 @@
                        return $root;
                }
 
-               if ( is_object( $this->parser->mOptions ) && 
++$this->parser->mPPNodeCount > $this->parser->mOptions->getMaxPPNodeCount() )
+               if ( ++$this->parser->mPPNodeCount > 
$this->parser->mOptions->getMaxPPNodeCount() )
                {
                        return '<span class="error">Node-count limit 
exceeded</span>';
                }
 
-               if ( is_object( $this->parser->mOptions ) && $expansionDepth > 
$this->parser->mOptions->getMaxPPExpandDepth() ) {
+               if ( $expansionDepth > 
$this->parser->mOptions->getMaxPPExpandDepth() ) {
                        return '<span class="error">Expansion depth limit 
exceeded</span>';
                }
                wfProfileIn( __METHOD__ );

Modified: trunk/phase3/includes/parser/Preprocessor_DOM.php
===================================================================
--- trunk/phase3/includes/parser/Preprocessor_DOM.php   2011-08-02 16:04:36 UTC 
(rev 93762)
+++ trunk/phase3/includes/parser/Preprocessor_DOM.php   2011-08-02 16:18:10 UTC 
(rev 93763)
@@ -956,12 +956,11 @@
                        return $root;
                }
 
-               if ( is_object( $this->parser->mOptions ) && 
++$this->parser->mPPNodeCount > $this->parser->mOptions->getMaxPPNodeCount() )
-               {
+               if ( ++$this->parser->mPPNodeCount > 
$this->parser->mOptions->getMaxPPNodeCount() ) {
                        return '<span class="error">Node-count limit 
exceeded</span>';
                }
 
-               if ( is_object( $this->parser->mOptions ) && $expansionDepth > 
$this->parser->mOptions->getMaxPPExpandDepth() ) {
+               if ( $expansionDepth > 
$this->parser->mOptions->getMaxPPExpandDepth() ) {
                        return '<span class="error">Expansion depth limit 
exceeded</span>';
                }
                wfProfileIn( __METHOD__ );


_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to