#23299 [Opn->Bgs]: Intermittant but reproducable corruption and crash

From: Date: Mon, 05 May 2003 21:18:36 +0000
Subject: #23299 [Opn->Bgs]: Intermittant but reproducable corruption and crash
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-39103@lists.php.net to get a copy of this message
ID: 23299 Updated by: moriyoshi@php.net Reported By: bginter at ndevtech dot net -Status: Open +Status: Bogus Bug Type: Reproducible crash Operating System: Linux 2.4.20 PHP Version: 4.3.2-RC New Comment: So that's not a developer issue. Previous Comments: ------------------------------------------------------------------------ [2003-05-05 16:17:39] moriyoshi@php.net I'm looking at crash1.php script. <?php $group = new Group; for ( $i = 0; $i < 15; $i++ ) { // uncomment this and it works // print $group->count() . "<br/>\n"; for ( $i = 0; $i < $assoc->count(); $i++ ) { // print "Getting company $i<br/>\n"; $company = $assoc->get( $i ); $group->add( $company ); } // print_d( $company ); } print_d( $company ); ?> The above part should be for ( $j = 0; $j < 15; $j++ ) { // not $i ! for ( $i = 0; $i < $assoc->count(); $i++ ) { $company = $assoc->get( $i ); Otherwise, it goes into an infinite loop when $assoc->count() is less than 15 and then PHP runs out of all the available memory to die. ------------------------------------------------------------------------ [2003-05-05 15:46:22] bginter at ndevtech dot net bginter@debian:~$ gcc --version 2.95.4 bginter@debian:~$ ld -v GNU ld version 2.12.90.0.1 20020307 Debian/GNU Linux ------------------------------------------------------------------------ [2003-05-05 15:14:34] moriyoshi@php.net Which version of gcc and binutils are you using? (appears related to bug #22510 & bug #22367) ------------------------------------------------------------------------ [2003-04-28 16:27:05] bginter at ndevtech dot net This continues to happen with php4-STABLE-200304281730. How can I further assist with this bug? ------------------------------------------------------------------------ [2003-04-24 13:12:55] bginter at ndevtech dot net Have you been able to reproduce this on your development machine? ------------------------------------------------------------------------ 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/23299 -- Edit this bug report at http://bugs.php.net/?id=23299&edit=1

« previous php.bugs (#39103) next »