cvs: pear-core(PEAR_1_3) / PEAR.php

From: Date: Fri, 22 Oct 2004 05:53:36 +0000
Subject: cvs: pear-core(PEAR_1_3) / PEAR.php
Groups: php.pear.cvs php.pear.core 
Request: Send a blank email to pear-core+get-1117@lists.php.net to get a copy of this message
cellog Fri Oct 22 01:53:36 2004 EDT Modified files: (Branch: PEAR_1_3) /pear-core PEAR.php Log: fix #1426 emulated destructors not called in reverse order use PEAR::getStaticProperty('PEAR', 'destructlifo') to control this behavior. Default is to be fifo (old behavior) http://cvs.php.net/diff.php/pear-core/PEAR.php?r1=1.82.2.3&r2=1.82.2.4&ty=u Index: pear-core/PEAR.php diff -u pear-core/PEAR.php:1.82.2.3 pear-core/PEAR.php:1.82.2.4 --- pear-core/PEAR.php:1.82.2.3 Fri Oct 22 01:45:23 2004 +++ pear-core/PEAR.php Fri Oct 22 01:53:36 2004 @@ -18,7 +18,7 @@ // | Tomas V.V.Cox <cox@idecnet.com> | // +--------------------------------------------------------------------+ // -// $Id: PEAR.php,v 1.82.2.3 2004/10/22 05:45:23 cellog Exp $ +// $Id: PEAR.php,v 1.82.2.4 2004/10/22 05:53:36 cellog Exp $ // define('PEAR_ERROR_RETURN', 1); @@ -741,6 +741,9 @@ sizeof($_PEAR_destructor_object_list)) { reset($_PEAR_destructor_object_list); + if (@PEAR::getStaticProperty('PEAR', 'destructlifo')) { + $_PEAR_destructor_object_list = array_reverse($_PEAR_destructor_object_list); + } while (list($k, $objref) = each($_PEAR_destructor_object_list)) { $classname = get_class($objref); while ($classname) {

« previous php.pear.core (#1117) next »