From: mail at ciruz dot de
Operating system: Linux (2.4.21)
PHP version: 5.0.0b1 (beta1)
PHP Bug Type: Reproducible crash
Bug description: PHP5 crashes on global
Description:
------------
PHP5 crashes with the attached code.
It seems to crash at the Entry 'GLOBAL' and some others.
Reproduce code:
---------------
This code is in a function. It should global every variable:
foreach($GLOBALS as $field=>$value) if($field!='t' && $field!='r' &&
$field!='field' && $field!='value') global ${$field};
The following code works, but is TOO SLOW!
foreach($GLOBALS as $field=>$value) if($field!='t' && $field!='r' &&
$field!='field' && $field!='value') eval('global $'.$field.';'); // Use
eval for PHP5 compatibility!
Expected result:
----------------
Every variable should be globales - only $t, $r, $field and $value not.
Actual result:
--------------
No output from PHP. It crashes and gives nothing back to Apache.
--
Edit bug report at http://bugs.php.net/?id=24619&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=24619&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=24619&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=24619&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=24619&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=24619&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=24619&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=24619&r=support
Expected behavior: http://bugs.php.net/fix.php?id=24619&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=24619&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=24619&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=24619&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=24619&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=24619&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=24619&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=24619&r=gnused