ID:               32968
 User updated by:  pasha dot zubkov at gmail dot com
-Summary:          Segfault after 14956 iteration of recursion
 Reported By:      pasha dot zubkov at gmail dot com
-Status:           Bogus
+Status:           Open
 Bug Type:         Zend Engine 2 problem
 Operating System: Linux 2.6.11.6-grsec
 PHP Version:      5.0.4
 New Comment:

It's bug, because when 'memory_limit' is set to small value I got
error:
"Allowed memory size of xxx bytes exhausted (tried to allocate xxx
bytes)".
But when 'memory_limit' is not set or set to large value, php
segfaults
after allocating all allowed stack memory restricted by ulimit.

Or I misunderstud you and segfault is "normal php mode"?

my ulimit output:
[EMAIL PROTECTED] ~]# ulimit -a
core file size        (blocks, -c) 0
data seg size         (kbytes, -d) unlimited
file size             (blocks, -f) unlimited
max locked memory     (kbytes, -l) 32
max memory size       (kbytes, -m) unlimited
open files                    (-n) 1024
pipe size          (512 bytes, -p) 8
stack size            (kbytes, -s) 8192
cpu time             (seconds, -t) unlimited
max user processes            (-u) 4095
virtual memory        (kbytes, -v) unlimited


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

[2005-05-06 19:50:00] [EMAIL PROTECTED]

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

.

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

[2005-05-06 18:35:38] pasha dot zubkov at gmail dot com

Description:
------------
both php-5.0.4 and php-PHP_5_0-05052005 segfaults with this code

Reproduce code:
---------------
<?php
function rec() {
        static $count = 0;
        echo "$count ";
        $count++;
        rec();
}
rec();
?>

Actual result:
--------------
[snip] 14954 14955 14956 Segmentation fault


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


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

Reply via email to