ID:               26696
 User updated by:  saruman at northernhacking dot org
 Reported By:      saruman at northernhacking dot org
 Status:           Open
 Bug Type:         Reproducible crash
 Operating System: Linux RH9
 PHP Version:      5.0.0b2 (beta2)
 New Comment:

In the code snippet, commenting out the content of the switch loop
prevents the crash.


Previous Comments:
------------------------------------------------------------------------

[2003-12-22 14:33:53] saruman at northernhacking dot org

Description:
------------
The ONLY change I'd done is install php-5.0.0b3 with the same config as
the php-5.0.0b2 it replaced.

Config vars:

Configure Command  './configure' '--with-pear' '--with-pgsql'
'--with-apxs=/usr/local/apache/bin/apxs' '--enable-mbstring'
'--prefix=/usr/local/php5' '--with-libxml-dir=/usr'

Using this with php-5.0.0b2 works as expected. This behavior of a
string is required by DB.php in PEAR, amongst others.

Reproduce code:
---------------
<?php

//$str = Array('a', 's', 'd', 'd', '/', '?');
$str = 'asdd/?';
$len = strlen($str);
for ($i = 0; $i < $len; $i++) {
        switch ($str[$i]) {
                case '?':
                        echo '?';
                        break;
        }
}

?>
Did not crash.

Expected result:
----------------
?Did not crash.

Actual result:
--------------
>From error_log:
[Mon Dec 22 14:15:38 2003] [notice] child pid 30170 exit signal
Segmentation fault (11)
[Mon Dec 22 14:15:38 2003] [notice] child pid 30187 exit signal
Segmentation fault (11)

The two response are because MSIE seems to do a second query when the
first one unexpectedly close.


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=26696&edit=1

Reply via email to