Re: Re: 5.0.5

From: Date: Thu, 08 Sep 2005 11:48:56 +0000
Subject: Re: Re: 5.0.5
References: 1 2 3 4 5 6 7 8 9 10  Groups: php.internals 
Request: Send a blank email to internals+get-18716@lists.php.net to get a copy of this message
Path for 5.0.6, it would seem odd to have a different behavior on the 5.0.x branch. Scott Derick Rethans wrote: > On Thu, 8 Sep 2005, Stanislav Malyshev wrote: > >> DR>>But they can still do that.. With "shutdown functions" I meant >> DR>>functions registered with register_shutdown_function(). >> >> Ah... This is smaller problem - register_shutdown_function() ones can be >> called on "before dtors" stage. > > Indeed, we've always done this too... I've a patch ready to commit for > PHP 5.1/6.0 for this: > > diff -u -p -d -r1.640 main.c > --- main.c 5 Aug 2005 21:44:26 -0000 1.640 > +++ main.c 8 Sep 2005 11:33:43 -0000 > @@ -1197,16 +1197,16 @@ void php_request_shutdown(void *dummy) > EG(opline_ptr) = NULL; > EG(active_op_array) = NULL; > > - /* 1. Call all possible __destruct() functions */ > - zend_try { > - zend_call_destructors(TSRMLS_C); > - } zend_end_try(); > - > - /* 2. Call all possible shutdown functions registered with register_shutdown_function() > */ > + /* 1. Call all possible shutdown functions registered with register_shutdown_function() > */ > if (PG(modules_activated)) zend_try { > php_call_shutdown_functions(TSRMLS_C); > } zend_end_try(); > > + /* 2. Call all possible __destruct() functions */ > + zend_try { > + zend_call_destructors(TSRMLS_C); > + } zend_end_try(); > + > /* 3. Flush all output buffers */ > zend_try { > php_end_ob_buffers((zend_bool)(SG(request_info).headers_only?0:1) TSRMLS_CC); > > > Derick

« previous php.internals (#18716) next »