#19172 [NEW]: limited recursive class call results segfault

From: Date: Thu, 29 Aug 2002 14:19:00 +0000
Subject: #19172 [NEW]: limited recursive class call results segfault
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-18153@lists.php.net to get a copy of this message
From: alberty@neptunelabs.de Operating system: i686-pc-linux-gnu PHP version: 4CVS-2002-08-29 PHP Bug Type: Reproducible crash Bug description: limited recursive class call results segfault Hi, the follow call results a segfault: <?php class foo { function out(){ static $stopper=0; if ($stopper < 10) $this->out(); $stopper++; } } $foo = new foo; $foo->out(); ?> Tested with gcc3.1.1 and libc2.2.4 here is the backtrace: Program received signal SIGSEGV, Segmentation fault. 0x4044d4cc in _get_zval_ptr (node=0x816b018, Ts=0xbf8000bc, should_free=0xbf80008c) at /usr/src/php4/Zend/zend_execute.c:71 71 { (gdb) bt #0 0x4044d4cc in _get_zval_ptr (node=0x816b018, Ts=0xbf8000bc, should_free=0xbf80008c) at /usr/src/php4/Zend/zend_execute.c:71 #1 0x40445495 in zend_fetch_var_address (opline=0x816b004, Ts=0xbf8000bc, type=1) at /usr/src/php4/Zend/zend_execute.c:529 #2 0x40447900 in execute (op_array=0x816bf34) at /usr/src/php4/Zend/zend_execute.c:1237 #3 0x40449b55 in execute (op_array=0x816bf34) at /usr/src/php4/Zend/zend_execute.c:1643 #4 0x40449b55 in execute (op_array=0x816bf34) at /usr/src/php4/Zend/zend_execute.c:1643 #5 0x40449b55 in execute (op_array=0x816bf34) at /usr/src/php4/Zend/zend_execute.c:1643 ... Regards, Steve -- Edit bug report at http://bugs.php.net/?id=19172&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=19172&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=19172&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=19172&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=19172&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=19172&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=19172&r=support Expected behavior: http://bugs.php.net/fix.php?id=19172&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=19172&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=19172&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=19172&r=globals

« previous php.bugs (#18153) next »