At 06:18 PM 9/14/2004 +0400, Antony Dovgal wrote:
Sounds nice: we should not call destructors after they were already called =)

I could propose a simple solution: add a global flag, which will indicate
that shutdown_destructors() was called, and do appropriate check in
zend_objects_store_del_ref().
Comments/objections?

I prefer not to add another if() to this method. I did my best to keep it as slim as possible.
We could run over the object store and mark all destructors as already called. That might be the best solution and wouldn't slow down the general case of objects being destroyed during script execution, but if there are lots of global objects it would potentially slow down the shutdown.


Andi

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to