cvs: /php4 main.c php_globals.h
| From: | Zeev Suraski | Date: | Sat, 26 Feb 2000 23:50:42 +0000 |
| Subject: | cvs: /php4 main.c php_globals.h | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-11060@lists.php.net to get a copy of this message | ||
zeev Sat Feb 26 15:50:42 2000 EDT
Modified files:
/php4 main.c php_globals.h
Log:
@- Fixed a (fairly common) situation where error_reporting values would not be
@ properly restored after a call to error_reporting(), in between requests (Zeev)
Index: php4/main.c
diff -u php4/main.c:1.223 php4/main.c:1.224
--- php4/main.c:1.223 Sat Feb 26 14:14:49 2000
+++ php4/main.c Sat Feb 26 15:50:11 2000
@@ -19,7 +19,7 @@
*/
-/* $Id: main.c,v 1.223 2000/02/26 22:14:49 zeev Exp $ */
+/* $Id: main.c,v 1.224 2000/02/26 23:50:11 zeev Exp $ */
#include <stdio.h>
@@ -133,13 +133,15 @@
static PHP_INI_MH(OnUpdateErrorReporting)
{
+ PLS_FETCH();
ELS_FETCH();
if (!new_value) {
- EG(error_reporting) = E_ALL & ~E_NOTICE;
+ PG(error_reporting) = E_ALL & ~E_NOTICE;
} else {
- EG(error_reporting) = atoi(new_value);
+ PG(error_reporting) = atoi(new_value);
}
+ EG(error_reporting) = PG(error_reporting);
return SUCCESS;
}
@@ -656,6 +658,7 @@
php_call_shutdown_functions();
php_ini_rshutdown();
+ EG(error_reporting) = PG(error_reporting);
zend_deactivate(CLS_C ELS_CC);
sapi_deactivate(SLS_C);
Index: php4/php_globals.h
diff -u php4/php_globals.h:1.45 php4/php_globals.h:1.46
--- php4/php_globals.h:1.45 Sat Feb 26 10:59:29 2000
+++ php4/php_globals.h Sat Feb 26 15:50:11 2000
@@ -72,6 +72,7 @@
long memory_limit;
+ int error_reporting;
zend_bool track_errors;
zend_bool display_errors;
zend_bool log_errors;