From: guth at fiifo dot u-psud dot fr Operating system: PHP version: 5.0.3 PHP Bug Type: Performance problem Bug description: Memory leak
Description: ------------ The following code produces a memory leak : /usr/src/php-5.0.3RC1/Zend/zend_execute.c(3255) : Freeing 0x0816FB6C (16 bytes), script=/www/test3.php === Total 1 memory leaks detected === Reproduce code: --------------- <?php class DbGow { public function query() { throw new Exception; } public function select() { return new DbGowRecordSet($this->query()); } } class DbGowRecordSet { public function __construct($resource) { } } $db = new DbGow; try { $rs = $db->select(); } catch(Exception $e) { } ?> -- Edit bug report at http://bugs.php.net/?id=31177&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=31177&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=31177&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=31177&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=31177&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=31177&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=31177&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=31177&r=needscript Try newer version: http://bugs.php.net/fix.php?id=31177&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=31177&r=support Expected behavior: http://bugs.php.net/fix.php?id=31177&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=31177&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=31177&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=31177&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=31177&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=31177&r=dst IIS Stability: http://bugs.php.net/fix.php?id=31177&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=31177&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=31177&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=31177&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=31177&r=mysqlcfg