From: Steve Sanbeg Date: Thu, 21 Dec 2006 00:07:13 +0000 (+0000) Subject: save path level before recursing into functions, for better cycle detection X-Git-Tag: 1.31.0-rc.0~54827 X-Git-Url: http://git.cyclocoop.org/%22.%24h.%22?a=commitdiff_plain;h=27895ef12a64b790174b89a3037cb967980639e2;p=lhc%2Fweb%2Fwiklou.git save path level before recursing into functions, for better cycle detection --- diff --git a/includes/Parser.php b/includes/Parser.php index 1642105916..545651242e 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -2957,6 +2957,9 @@ class Parser } wfProfileOut( __METHOD__.'-modifiers' ); + //save path level before recursing into functions & templates. + $lastPathLevel = $this->mTemplatePath; + # Parser functions if ( !$found ) { wfProfileIn( __METHOD__ . '-pfunc' ); @@ -3025,7 +3028,6 @@ class Parser } # Load from database - $lastPathLevel = $this->mTemplatePath; if ( !$found ) { wfProfileIn( __METHOD__ . '-loadtpl' ); $ns = NS_TEMPLATE;