#33454 [NEW]: Semgantation fault performing eval in __destruct()

From: Date: Thu, 23 Jun 2005 15:08:30 +0000
Subject: #33454 [NEW]: Semgantation fault performing eval in __destruct()
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-80914@lists.php.net to get a copy of this message
From: carlo dot razzeto at mtginfo dot com Operating system: (Red Hat Linux 3.2.3-47) PHP version: 5.0.4 PHP Bug Type: Reproducible crash Bug description: Semgantation fault performing eval in __destruct() Description: ------------ The latest release of PHP5 will segmantation fault when performing the following an eval which accesses a member variable of the class, setting another variable to it's value. Reproduce code: --------------- class test { var $test = true; function __construct() { //Constructor } function __destruct() { $variable = 'test'; $test = true; eval( '$check = $this->'.$variable.';' ); if( $check ) { echo "Hello\n"; } } } $o_test = new test(); Expected result: ---------------- Hello prompt: Actual result: -------------- Segmantation Fault: prompt: -- Edit bug report at http://bugs.php.net/?id=33454&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=33454&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=33454&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=33454&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=33454&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=33454&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=33454&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=33454&r=needscript Try newer version: http://bugs.php.net/fix.php?id=33454&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=33454&r=support Expected behavior: http://bugs.php.net/fix.php?id=33454&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=33454&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=33454&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=33454&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=33454&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=33454&r=dst IIS Stability: http://bugs.php.net/fix.php?id=33454&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=33454&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=33454&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=33454&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=33454&r=mysqlcfg

« previous php.bugs (#80914) next »