From:             navyism at chol dot com
Operating system: linux
PHP version:      4.3.8
PHP Bug Type:     Unknown/Other Function
Bug description:  unknown unterminated loop

Description:
------------
"$a = $a . $b;" make a unterminated loop.

-> my solutions
1. $a = $a . $b; => $a .= $b;
2. for ($i=0; $i<10; $i++) => for ($i=0; $i<(int)10; $i++) 



Reproduce code:
---------------
<?
$a = $a . $b;
$a = $a . $b;
$a = $a . $b;
$a = $a . $b;
$a = $a . $b;
$a = $a . $b;
$a = $a . $b;

for ($i=0; $i<10; $i++) {
        if($i > 100) die('[EMAIL PROTECTED]');
}

for ($i=0; $i<10; $i++) {
        if($i > 100) die('[EMAIL PROTECTED]');
}

for ($i=0; $i<10; $i++) {
        if($i > 100) die('[EMAIL PROTECTED]');
}

die('OK');
?>

Expected result:
----------------
OK

Actual result:
--------------
[EMAIL PROTECTED]

-- 
Edit bug report at http://bugs.php.net/?id=30307&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=30307&r=trysnapshot4
Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=30307&r=trysnapshot50
Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=30307&r=trysnapshot51
Fixed in CVS:                http://bugs.php.net/fix.php?id=30307&r=fixedcvs
Fixed in release:            http://bugs.php.net/fix.php?id=30307&r=alreadyfixed
Need backtrace:              http://bugs.php.net/fix.php?id=30307&r=needtrace
Need Reproduce Script:       http://bugs.php.net/fix.php?id=30307&r=needscript
Try newer version:           http://bugs.php.net/fix.php?id=30307&r=oldversion
Not developer issue:         http://bugs.php.net/fix.php?id=30307&r=support
Expected behavior:           http://bugs.php.net/fix.php?id=30307&r=notwrong
Not enough info:             http://bugs.php.net/fix.php?id=30307&r=notenoughinfo
Submitted twice:             http://bugs.php.net/fix.php?id=30307&r=submittedtwice
register_globals:            http://bugs.php.net/fix.php?id=30307&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=30307&r=php3
Daylight Savings:            http://bugs.php.net/fix.php?id=30307&r=dst
IIS Stability:               http://bugs.php.net/fix.php?id=30307&r=isapi
Install GNU Sed:             http://bugs.php.net/fix.php?id=30307&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=30307&r=float
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=30307&r=mysqlcfg

Reply via email to