1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

Allow using fast destruction path when ASAN is in use (#18835)

This commit is contained in:
Daniil Gentili
2025-06-30 18:37:20 +02:00
committed by GitHub
parent a1d4b18d8d
commit f6f0aed9f3

View File

@@ -438,6 +438,12 @@ void shutdown_executor(void) /* {{{ */
zval *zv;
#if ZEND_DEBUG
bool fast_shutdown = 0;
#elif defined(__SANITIZE_ADDRESS__)
char *force_fast_shutdown = getenv("ZEND_ASAN_FORCE_FAST_SHUTDOWN");
bool fast_shutdown = (
is_zend_mm()
|| (force_fast_shutdown && ZEND_ATOL(force_fast_shutdown))
) && !EG(full_tables_cleanup);
#else
bool fast_shutdown = is_zend_mm() && !EG(full_tables_cleanup);
#endif