summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2019-06-28 10:43:56 +0300
committerDmitry Stogov <dmitry@zend.com>2019-06-28 10:43:56 +0300
commitba8033feb0c2e8c6665a55d13ae2d0957ce72add (patch)
treec238ffe510953551a24b842238c4d95bc587a6a4
parentf365d0e00ed93b1c33e984ff3b4cc8677cbca193 (diff)
downloadphp-git-ba8033feb0c2e8c6665a55d13ae2d0957ce72add.tar.gz
Fixed use-after-free
-rw-r--r--Zend/zend_execute_API.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c
index 4117b48baf..7606351a0f 100644
--- a/Zend/zend_execute_API.c
+++ b/Zend/zend_execute_API.c
@@ -359,6 +359,7 @@ void shutdown_executor(void) /* {{{ */
if (ht) {
ZEND_ASSERT(GC_REFCOUNT(ht) == 1);
zend_array_destroy(ht);
+ ZEND_MAP_PTR_SET(op_array->static_variables_ptr, NULL);
}
}
} ZEND_HASH_FOREACH_END();
@@ -390,6 +391,7 @@ void shutdown_executor(void) /* {{{ */
if (ht) {
ZEND_ASSERT(GC_REFCOUNT(ht) == 1);
zend_array_destroy(ht);
+ ZEND_MAP_PTR_SET(op_array->static_variables_ptr, NULL);
}
}
}