ID:               30466
 Updated by:       [EMAIL PROTECTED]
 Reported By:      i dot oppenheim at xs4all dot nl
-Status:           Open
+Status:           Bogus
 Bug Type:         Reproducible crash
 Operating System: Linux 2.6.6-1um
 PHP Version:      4.3.9
 New Comment:

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

 expected behaviour.


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

[2004-10-18 14:23:10] [EMAIL PROTECTED]

No, PHP should not detect it and crash (this is the only time this is
permitted).

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

[2004-10-18 13:23:14] i dot oppenheim at xs4all dot nl

You can download the complete traceback from here:
http://dj.xs4all.nl/gdb.tar.gz

The bug seems to be that PHP does not notice that it runs out of stack
memory.

PHP should abort the function with an appropriate error message, rather
than crashing with a segmentation fault.
Furthermore, this condition should be documented in the
PHP manual.

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

[2004-10-18 11:06:23] [EMAIL PROTECTED]

Can you please put it online andprovide a link? It simple looks like a
stack overflow though.

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

[2004-10-18 11:04:03] i dot oppenheim at xs4all dot nl

I reconfigured PHP with --enable-debug.

Here is a fragment of the requested gdb backtrace (in total 8MB
large!):

Core was generated by `php-dbg ./tst.php'.
Program terminated with signal 11, Segmentation fault.
#0  0x080d915d in match (
    eptr=0x82e5603 "m.  Free membership via\n&gt; <a 
href=\"http://www.myjewish
learning.com/shamash", '-' <repeats 24 times>,
"\">http://www.myjewishlearning.c
om/shamash", '-' <repeats 24 times>, "</a>\n&gt; hanashir (at)
shamash(d"...,
    ecode=0x82ca027 "\v=", offset_top=4, md=0xbfffce1c, ims=0,
    eptrb=0xbf8001c4, flags=2) at
/opt/php/src/php/ext/pcre/pcrelib/pcre.c:5484
5484    {
#0  0x080d915d in match (
    eptr=0x82e5603 "m.  Free membership via\n&gt; <a 
href=\"http://www.myjewish
learning.com/shamash", '-' <repeats 24 times>,
"\">http://www.myjewishlearning.c
om/shamash", '-' <repeats 24 times>, "</a>\n&gt; hanashir (at)
shamash(d"...,
    ecode=0x82ca027 "\v=", offset_top=4, md=0xbfffce1c, ims=0,
    eptrb=0xbf8001c4, flags=2) at
/opt/php/src/php/ext/pcre/pcrelib/pcre.c:5484

<snip>

#21813 0x080e0faf in php_pcre_replace (
    regex=0x82d63e4 "[Hosted by Shamash:(.|\n)*</pre>]", regex_len=32,
    subject=0x82de53c "<!-- MHonArc v2.6.8 -->\n<!--X-Subject:
[HANASHIR:15052]
Re: cantorial certification(long) -->\n<!--X-From-R13: \"Oqevna
Rheyrfgre\" <nqe
vnaNqheyrfgre.pbz> -->\n<!--X-Date: 11 Aug 2003 14:20:34 &#45;0000
-"...,
    subject_len=31633, replace_val=0x82d58c4, is_callable_replace=0,
    result_len=0xbfffd00c, limit=-1)
    at /opt/php/src/php/ext/pcre/php_pcre.c:867
#21814 0x080e1964 in php_replace_in_subject (regex=0x82d5d14,
    replace=0x82d58c4, subject=0x82cab68, result_len=0xbfffd00c,
limit=-1,
    is_callable_replace=0 '\0') at
/opt/php/src/php/ext/pcre/php_pcre.c:1078
#21815 0x080e2087 in preg_replace_impl (ht=3, return_value=0x82d643c,
    this_ptr=0x0, return_value_used=1, is_callable_replace=0 '\0')
    at /opt/php/src/php/ext/pcre/php_pcre.c:1170
#21816 0x080e20dc in zif_preg_replace (ht=3, return_value=0x82d643c,
    this_ptr=0x0, return_value_used=1)
    at /opt/php/src/php/ext/pcre/php_pcre.c:1181
#21817 0x081c6333 in execute (op_array=0x82d57e8)
    at /opt/php/src/php/Zend/zend_execute.c:1640
#21818 0x081c6531 in execute (op_array=0x82d0264)
    at /opt/php/src/php/Zend/zend_execute.c:1684
#21819 0x081b53e9 in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
    at /opt/php/src/php/Zend/zend.c:891
#21820 0x08181774 in php_execute_script (primary_file=0xbffff630)
    at /opt/php/src/php/main/main.c:1735
#21821 0x081d646b in main (argc=2, argv=0xbffff6b4)
    at /opt/php/src/php/sapi/cli/php_cli.c:822
#21817 0x081c6333 in execute (op_array=0x82d57e8)
    at /opt/php/src/php/Zend/zend_execute.c:1640

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

[2004-10-18 07:55:57] [EMAIL PROTECTED]

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.

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

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/30466

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

Reply via email to