#23534 [Opn]: while and for loops getting stuck when counter check exceeds 13

From: Date: Thu, 08 May 2003 06:08:35 +0000
Subject: #23534 [Opn]: while and for loops getting stuck when counter check exceeds 13
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-39275@lists.php.net to get a copy of this message
ID: 23534 User updated by: mark at onelauter dot com Reported By: mark at onelauter dot com Status: Open Bug Type: Scripting Engine problem Operating System: Windows 2000 Server PHP Version: 4.3.1 New Comment: I don't know if it will help, but this sample also doesn't work. <?php for ($i=0;$i < 15;$i++) { ?> test <? } ?> There seems to be an issue with the output buffer. FWIW, I have buffering turned off to avoid the performance hit. Previous Comments: ------------------------------------------------------------------------ [2003-05-08 00:51:05] mark at onelauter dot com I found the same issue with "print" as I did with "echo". ------------------------------------------------------------------------ [2003-05-08 00:22:52] mark at onelauter dot com One new important development. I just figured out that its not the while loop or for loop that are generating the problem. This works. while ($i < 50) { $i++; } echo "$i "; However, if I put 14 echo statements in the file it fails. In other words, this works. echo "1"; echo "2"; ... lots of echos ... echo "13"; But if I add one more echo to the file it goes off into never never land. ------------------------------------------------------------------------ [2003-05-07 23:41:10] mark at onelauter dot com I should mention that these scripts are currently running fine on an older windows 2000 server. Since I want to retire this box I basically copied the existing installation to the new machine and adjusted NTFS permissions, set up IIS to use the ISAPI version and everything worked fine (as far as i can tell) except for this looping issue. ------------------------------------------------------------------------ [2003-05-07 23:37:10] mark at onelauter dot com Thank you for the fast reply, I tried the snapshot located here: http://snaps.php.net/win32/php4-win32-STABLE-latest.zip I still have the same problem. I tried an older version too (4.2.x) and it also couldn't count higher than 13. I could prearrange to have this server open live to the internet for a short period so that someone could check my test script with php info if that would help. ------------------------------------------------------------------------ [2003-05-07 16:29:24] moriyoshi@php.net Please try using this CVS snapshot: http://snaps.php.net/php4-STABLE-latest.tar.gz For Windows: http://snaps.php.net/win32/php4-win32-STABLE-latest.zip ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/23534 -- Edit this bug report at http://bugs.php.net/?id=23534&edit=1

« previous php.bugs (#39275) next »