#33083 [Opn->WFx]: Segmentation fault on recursive set_error_handler calls
| From: | tony2001@php.net | Date: | Fri, 20 May 2005 14:51:36 +0000 |
| Subject: | #33083 [Opn->WFx]: Segmentation fault on recursive set_error_handler calls | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-79265@lists.php.net to get a copy of this message | ||
ID: 33083
Updated by: tony2001@php.net
Reported By: ron at nexweb dot ca
-Status: Open
+Status: Wont fix
Bug Type: Unknown/Other Function
Operating System: Linux 2.4.28
PHP Version: 5.0.4
New Comment:
There is no protection against infinite resursion.
Previous Comments:
------------------------------------------------------------------------
[2005-05-20 16:29:20] ron at nexweb dot ca
Description:
------------
PHP gives a Segmentation fault on execution of the code below...
The logic error is obvious but in application this may happen...
Reproduce code:
---------------
#!/usr/local/bin/php -c/usr/local/php/lib/php.ini
<?php
function err_handler($errno, $errstr, $errfile, $errline)
{
createAnotherError();
}
function createAnotherError()
{
set_error_handler("err_handler");
trigger_error("error 2");
}
set_error_handler("err_handler");
trigger_error("error 1");
?>
Expected result:
----------------
An error message maybe that tells recursivity or tells error happen in
error handler...
Actual result:
--------------
Segmentation fault
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=33083&edit=1