Permalink
Browse files

error_reporting fix

  • Loading branch information...
1 parent 33471de commit fde2e61d544cdb2afe4594808b75ed6d174066cf @zsuraski zsuraski committed Jun 30, 2000
Showing with 6 additions and 1 deletion.
  1. +1 −1 Zend/zend_builtin_functions.c
  2. +4 −0 Zend/zend_execute_API.c
  3. +1 −0 Zend/zend_globals.h
@@ -342,7 +342,7 @@ ZEND_FUNCTION(error_reporting)
WRONG_PARAM_COUNT;
break;
}
-
+
RETVAL_LONG(old_error_reporting);
}
View
@@ -145,6 +145,8 @@ void init_executor(CLS_D ELS_DC)
zend_ptr_stack_init(&EG(user_error_handlers));
+ EG(orig_error_reporting) = EG(error_reporting);
+
#ifdef ZEND_WIN32
EG(timed_out) = 0;
#endif
@@ -203,6 +205,8 @@ void shutdown_executor(ELS_D)
zend_ptr_stack_clean(&EG(user_error_handlers), ZVAL_DESTRUCTOR, 1);
zend_ptr_stack_destroy(&EG(user_error_handlers));
+
+ EG(error_reporting) = EG(orig_error_reporting);
}
View
@@ -150,6 +150,7 @@ struct _zend_executor_globals {
jmp_buf bailout;
int error_reporting;
+ int orig_error_reporting;
zend_op_array *active_op_array;
zend_op_array *main_op_array;

0 comments on commit fde2e61

Please sign in to comment.