#46196 [Com]: restore_error_handler() broken

From: Date: Fri, 14 Nov 2008 16:59:25 +0000
Subject: #46196 [Com]: restore_error_handler() broken
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-130967@lists.php.net to get a copy of this message
ID: 46196 Comment by: olivier at ajeux dot com Reported By: php at benjaminschulz dot com Status: Open Bug Type: Scripting Engine problem Operating System: * PHP Version: 5.3CVS-2008-11-11 New Comment: I tested several export from CVS and I found when was commited the bug: 2008-08-11 17:00 GMT: OK (no bug) 2008-08-11 17:30 GMT: ERROR (bug happened). Script used for information: $ cvs -d :pserver:cvsread@cvs.php.net:/repository checkout -r PHP_5_3 -D"2008-08-11 17:30 GMT" php-src $ cd php-src $ ./buildconf --force && ./configure && make I hope it can help. This is a major bug for me. Previous Comments: ------------------------------------------------------------------------ [2008-11-13 17:22:46] webmaster at ajeux dot com I have tested tagged version in CVS: php_5_3_0alpha1: OK (no bug) php_5_3_0alpha2: ERROR (bug happened). So, it seems this bug was introduced between alpha1 and alpha2. If you give me a way to export cvs at a precise date, I can adjust when and where this bug was commited. ------------------------------------------------------------------------ [2008-11-11 10:42:11] jani@php.net Works fine with PHP_5_2, does not with PHP_5_3. ------------------------------------------------------------------------ [2008-10-31 16:05:13] olivier at ajeux dot com Same bug encountered with php5.3-200810301330, also with a php crash. Reproduce code: --------------- <?php var_dump ( set_error_handler ('myErrorHandler') ); restore_error_handler (); var_dump ( set_error_handler ('myErrorHandler') ); function myErrorHandler($errno, $errstr, $errfile, $errline) { return true; } Expected result: ---------------- NULL NULL Actual result: -------------- NULL string(14) "myErrorHandler" zend_mm_heap corrupted ------------------------------------------------------------------------ [2008-09-29 12:37:14] php at benjaminschulz dot com Description: ------------ restore_error_handler doesn't work anymore in PHP 5.3.0alpha3-dev (cli) (built: Sep 29 2008 12:17:38) Reproduce code: --------------- function foo() { var_dump(__FUNCTION__); } set_error_handler("foo"); restore_error_handler(); trigger_error("foobar", E_USER_ERROR);' Expected result: ---------------- A standard error message. Actual result: -------------- string(3) "foo" ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=46196&edit=1

« previous php.bugs (#130967) next »