From 4970926e4543c15e16b0c047d85dddfb4c09b581 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Sun, 12 Aug 2012 20:58:09 +0800 Subject: Fixed bug #62763 (register_shutdown_function and extending class) --- ext/standard/basic_functions.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'ext/standard/basic_functions.c') diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 99831a1f42..4858b6e375 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -5108,8 +5108,11 @@ void php_free_shutdown_functions(TSRMLS_D) /* {{{ */ zend_hash_destroy(BG(user_shutdown_function_names)); FREE_HASHTABLE(BG(user_shutdown_function_names)); BG(user_shutdown_function_names) = NULL; - } - zend_end_try(); + } zend_catch { + /* maybe shutdown method call exit, we just ignore it */ + FREE_HASHTABLE(BG(user_shutdown_function_names)); + BG(user_shutdown_function_names) = NULL; + } zend_end_try(); } /* }}} */ -- cgit v1.2.1