From:             webmaster at martialartsmovies dot net
Operating system: Windows XP
PHP version:      5.0.1
PHP Bug Type:     Arrays related
Bug description:  array_filter crashes Apache 2

Description:
------------
I have PHP 5.0.1 installed together with the latest stable Apache 2 on
Windows XP SP2. I used the example on the array_filter page on php.net an
all I got was a window telling me that apache caused a problem and it
needed to reboot.

Reproduce code:
---------------
<?php
function odd($var)
{
   return($var % 2 == 1);
}

function even($var)
{
   return($var % 2 == 0);
}

$array1 = array("a"=>1, "b"=>2, "c"=>3, "d"=>4, "e"=>5);
$array2 = array(6, 7, 8, 9, 10, 11, 12);

echo "Odd :\n";
print_r(array_filter($array1, "odd"));
echo "Even:\n";
print_r(array_filter($array2, "even"));
?> 

Expected result:
----------------
the array_filter function applied to the 2 arrays

Actual result:
--------------
apache 2 crashed.
error.log:
[Wed Sep 01 19:47:14 2004] [notice] Child 2412: Child process is running
[Wed Sep 01 19:47:14 2004] [notice] Child 2412: Acquired the start mutex.
[Wed Sep 01 19:47:14 2004] [notice] Child 2412: Starting 250 worker
threads.
[Wed Sep 01 19:50:15 2004] [notice] Parent: child process exited with
status 3221225477 -- Restarting.

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

Reply via email to