summaryrefslogtreecommitdiff
path: root/Zend/zend.c
diff options
context:
space:
mode:
authorSean Finney <seanius@debian.org>2009-06-24 22:49:04 +0200
committerSean Finney <seanius@debian.org>2009-06-24 22:49:04 +0200
commit84f4ca9b07fe5b73d840258f4aa7c1eb534c4253 (patch)
tree9829bd578af8a4a8b42b04277f9067e00dc5ad90 /Zend/zend.c
parent6821b67124604da690c5e9276d5370d679c63ac8 (diff)
downloadphp-84f4ca9b07fe5b73d840258f4aa7c1eb534c4253.tar.gz
Imported Upstream version 5.3.0~RC4upstream/5.3.0_RC4upstream/5.3.0.RC4
Diffstat (limited to 'Zend/zend.c')
-rw-r--r--Zend/zend.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/Zend/zend.c b/Zend/zend.c
index a27eb3d75..a5f5a58b8 100644
--- a/Zend/zend.c
+++ b/Zend/zend.c
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend.c,v 1.308.2.12.2.35.2.30 2009/03/18 10:18:09 dmitry Exp $ */
+/* $Id: zend.c,v 1.308.2.12.2.35.2.33 2009/06/16 16:10:15 rasmus Exp $ */
#include "zend.h"
#include "zend_extensions.h"
@@ -863,7 +863,7 @@ void zend_deactivate_modules(TSRMLS_D) /* {{{ */
EG(opline_ptr) = NULL; /* we're no longer executing anything */
zend_try {
- zend_hash_apply(&module_registry, (apply_func_t) module_registry_cleanup TSRMLS_CC);
+ zend_hash_reverse_apply(&module_registry, (apply_func_t) module_registry_cleanup TSRMLS_CC);
} zend_end_try();
}
/* }}} */
@@ -1133,7 +1133,7 @@ ZEND_API void zend_error(int type, const char *format, ...) /* {{{ */
}
/* }}} */
-#if defined(__GNUC__) && !defined(__INTEL_COMPILER) && !defined(DARWIN) && !defined(__hpux) && !defined(_AIX) && !defined(__osf__)
+#if defined(__GNUC__) && __GNUC__ >= 3 && !defined(__INTEL_COMPILER) && !defined(DARWIN) && !defined(__hpux) && !defined(_AIX) && !defined(__osf__)
void zend_error_noreturn(int type, const char *format, ...) __attribute__ ((alias("zend_error"),noreturn));
#endif
@@ -1192,20 +1192,20 @@ ZEND_API int zend_execute_scripts(int type TSRMLS_DC, zval **retval, int file_co
zval *orig_user_exception_handler;
zval **params[1], *retval2, *old_exception;
old_exception = EG(exception);
- zend_exception_save(TSRMLS_C);
+ EG(exception) = NULL;
params[0] = &old_exception;
orig_user_exception_handler = EG(user_exception_handler);
if (call_user_function_ex(CG(function_table), NULL, orig_user_exception_handler, &retval2, 1, params, 1, NULL TSRMLS_CC) == SUCCESS) {
if (retval2 != NULL) {
zval_ptr_dtor(&retval2);
}
- zend_exception_restore(TSRMLS_C);
if (EG(exception)) {
zval_ptr_dtor(&EG(exception));
EG(exception) = NULL;
}
+ zval_ptr_dtor(&old_exception);
} else {
- zend_exception_restore(TSRMLS_C);
+ EG(exception) = old_exception;
zend_exception_error(EG(exception), E_ERROR TSRMLS_CC);
}
} else {