#30998 [Opn->Csd]: Crash when user error handler returns false
| From: | stas@php.net | Date: | Mon, 06 Dec 2004 15:50:40 +0000 |
| Subject: | #30998 [Opn->Csd]: Crash when user error handler returns false | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-69846@lists.php.net to get a copy of this message | ||
ID: 30998
Updated by: stas@php.net
Reported By: stas@php.net
-Status: Open
+Status: Closed
Bug Type: Reproducible crash
Operating System: Linux/amd64
-PHP Version: 4.3.9
+PHP Version: any
New Comment:
Affects both PHP4 and PHP5, fixed in both.
Previous Comments:
------------------------------------------------------------------------
[2004-12-06 16:40:30] stas@php.net
Description:
------------
If user error handler returns false on amd64, PHP crashes. This is due
to the fact that zend_error uses va_list twice, which does not work on
systems where va_arg modifies va_list.
Reproduce code:
---------------
<?
function my_error($errno, $errstr, $errfile, $errline)
{
print "$errstr ($errno) in $errfile:$errline\n";
return false;
}
set_error_handler('my_error');
$f = fopen("/tmp/blah", "r");
?>
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=30998&edit=1