Edit report at https://bugs.php.net/bug.php?id=64135&edit=1
ID: 64135 Updated by: larue...@php.net Reported by: za_creature at yahoo dot com Summary: Exceptions from set_error_handler are not always propagated -Status: Assigned +Status: Closed Type: Bug Package: Scripting Engine problem Operating System: WOW64, CentOS6.3 PHP Version: 5.4.11 Assigned To: dmitry Block user comment: N Private report: N New Comment: Automatic comment on behalf of laruence Revision: http://git.php.net/?p=php-src.git;a=commit;h=290509755ac4a3279b2b31b899aa9f2dd780f5f4 Log: Fixed bug #64135 (Exceptions from set_error_handler are not always propagated) Previous Comments: ------------------------------------------------------------------------ [2013-02-07 14:26:05] larue...@php.net okey, I will commit it to 5.5 and above ------------------------------------------------------------------------ [2013-02-04 08:12:47] dmi...@php.net I don't see any problems with the patch. ------------------------------------------------------------------------ [2013-02-04 07:00:04] larue...@php.net patch attached, but I think maybe only going into PHP 5.5, this could be considered a BC break. what do you think, dmitry? thanks ------------------------------------------------------------------------ [2013-02-04 06:56:12] larue...@php.net The following patch has been added/updated: Patch Name: bug64135.patch Revision: 1359960972 URL: https://bugs.php.net/patch-display.php?bug=64135&patch=bug64135.patch&revision=1359960972 ------------------------------------------------------------------------ [2013-02-02 16:55:11] za_creature at yahoo dot com Description: ------------ echo $undefined works $undefined++ works $undefined->method() doesn't Test script: --------------- <?php function exception_error_handler() { throw new Exception(); } set_error_handler("exception_error_handler"); try { $undefined->method(); } catch(Exception $e) { echo "Exception is thrown"; } Expected result: ---------------- Exception is thrown Actual result: -------------- PHP Warning: Uncaught exception 'Exception' in /home/radu/bug.php:4 Stack trace: #0 /home/radu/bug.php(9): exception_error_handler(8, 'Undefined varia...', '/home/radu/bug....', 9, Array) #1 {main} thrown in /home/radu/bug.php on line 4 Warning: Uncaught exception 'Exception' in /home/radu/bug.php:4 Stack trace: #0 /home/radu/bug.php(9): exception_error_handler(8, 'Undefined varia...', '/home/radu/bug....', 9, Array) #1 {main} thrown in /home/radu/bug.php on line 4 PHP Fatal error: Call to a member function method() on a non-object in /home/radu/bug.php on line 9 ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=64135&edit=1