From:             Xuefer at 21cn dot com
Operating system: win32
PHP version:      4.3.2
PHP Bug Type:     Scripting Engine problem
Bug description:  crash: parent to reference to child, followed by a for/count empty 
loop

Description:
------------
crash in page 2nd time loading
let the code say everything

Reproduce code:
---------------
$match = array( 0 => array("1", "2", "3", "4", "5"));
$match = &$match[0];
for ($i = 0, $c = count($match); $i < $c; $i ++) {
  // empty loop
}

however, the following code will not crash:
$match = array( 0 => array("1", "2", "3", "4", "5"));
$match = &$match[0];
echo $c = count($match);
for ($i = 0, $c = count($match); $i < $c; $i ++) {
  // empty loop
}

Expected result:
----------------
should not crash

Actual result:
--------------
but it did crash :(

-- 
Edit bug report at http://bugs.php.net/?id=24222&edit=1
-- 
Try a CVS snapshot:         http://bugs.php.net/fix.php?id=24222&r=trysnapshot
Fixed in CVS:               http://bugs.php.net/fix.php?id=24222&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=24222&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=24222&r=needtrace
Try newer version:          http://bugs.php.net/fix.php?id=24222&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=24222&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=24222&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=24222&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=24222&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=24222&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=24222&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=24222&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=24222&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=24222&r=gnused

Reply via email to