com php-src: Reset globals on startup or restart: main/main.c
| From: | Dmitry Stogov | Date: | Wed, 19 Jul 2017 12:35:10 +0000 |
| Subject: | com php-src: Reset globals on startup or restart: main/main.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-98635@lists.php.net to get a copy of this message | ||
Commit: e5beb4e828b2b9b3d79642bd407813c824950310
Author: Dmitry Stogov <dmitry@zend.com> Wed, 19 Jul 2017 15:35:10 +0300
Parents: afc22828ea036814e6a044083dade065b4c858c9
Branches: PHP-7.0 PHP-7.1 PHP-7..2 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=e5beb4e828b2b9b3d79642bd407813c824950310
Log:
Reset globals on startup or restart
Changed paths:
M main/main.c
Diff:
diff --git a/main/main.c b/main/main.c
index 01ed3a6..4b145fc 100644
--- a/main/main.c
+++ b/main/main.c
@@ -2061,6 +2061,7 @@ int php_module_startup(sapi_module_struct *sf, zend_module_entry
*additional_mod
ts_allocate_id(&php_win32_core_globals_id, sizeof(php_win32_core_globals), (ts_allocate_ctor)
php_win32_core_globals_ctor, (ts_allocate_dtor) php_win32_core_globals_dtor);
#endif
#else
+ memset(&core_globals, 0, sizeof(core_globals));
php_startup_ticks();
#endif
gc_globals_ctor();