summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--main/main.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/main/main.c b/main/main.c
index 7ac337bd33..236209a41c 100644
--- a/main/main.c
+++ b/main/main.c
@@ -111,7 +111,7 @@ void *gLock; /*mutex variable */
HashTable configuration_hash;
char *php3_ini_path = NULL;
#ifdef ZTS
-php_core_globals *main_core_globals;
+php_core_globals *main_core_globals=NULL;
#endif
@@ -784,7 +784,9 @@ static void php3_config_ini_shutdown()
#ifdef ZTS
static core_globals_ctor(php_core_globals *core_globals)
{
+ if (main_core_globals) {
*core_globals = *main_core_globals;
+ }
}
#endif