summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--phpdbg.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/phpdbg.c b/phpdbg.c
index 7a5cd48e43..c6d44ba3ae 100644
--- a/phpdbg.c
+++ b/phpdbg.c
@@ -1217,6 +1217,13 @@ phpdbg_out:
goto phpdbg_interact;
}
#endif
+
+#ifndef ZTS
+ /* force cleanup of auto and core globals */
+ zend_hash_clean(CG(auto_globals));
+ memset(
+ &core_globals, 0, sizeof(php_core_globals));
+#endif
if (ini_entries) {
free(ini_entries);