mirror of
https://github.com/php/php-src.git
synced 2024-12-25 01:40:50 +08:00
bd6eabd659
We only need to do this once we're running destructors. The current approach interferes with some event loop code that runs everything inside a shutdown function.
15 lines
236 B
PHP
15 lines
236 B
PHP
--TEST--
|
|
Bug object gc not working in shutdown
|
|
--FILE--
|
|
<?php
|
|
ini_set('memory_limit', '2M');
|
|
register_shutdown_function(function () {
|
|
for ($n = 1000 * 1000; $n--;) {
|
|
new stdClass;
|
|
}
|
|
echo "OK\n";
|
|
});
|
|
?>
|
|
--EXPECT--
|
|
OK
|