PHP 4.0 Bug #4750: When storing resource objects in static variables, PHP goes into a deadly loop.

From: Date: Thu, 01 Jun 2000 10:26:07 +0000
Subject: PHP 4.0 Bug #4750: When storing resource objects in static variables, PHP goes into a deadly loop.
Groups: php.dev 
Request: Send a blank email to php-dev+get-19945@lists.php.net to get a copy of this message
From: php@raylucke.com Operating system: Linux PHP version: 4.0.0 Release PHP Bug Type: Reproduceable crash Bug description: When storing resource objects in static variables, PHP goes into a deadly loop. The faulty code is below. This is a VERY bad bug. It will cause Apache / PHP to eat CPU cycles and put in the log the following line continuously:<br> Fatal error ht=40310d44 is already destroyed in zend_hash.c:519 in Unknown on line 0<br> This is not a dir() bug. It happens any time you try to store a resource object (such as dir(), mysql_query(), etc.) in a static variable.<br><br> &lt;? static $t = 0; $t = dir("."); ?&gt;

« previous php.dev (#19945) next »