From 2f1e45e8733fd62223ae36df278a12b7523ae0aa Mon Sep 17 00:00:00 2001 From: Ilija Tovilo Date: Thu, 9 Mar 2023 21:50:18 +0100 Subject: [PATCH] Disable asan instrumentation for phpdbg_watchpoint_userfaultfd_thread On gcc. It reports a false positive stack-overflow. --- sapi/phpdbg/phpdbg_watch.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sapi/phpdbg/phpdbg_watch.c b/sapi/phpdbg/phpdbg_watch.c index 86cd64a5721ff..0468d4614fd5d 100644 --- a/sapi/phpdbg/phpdbg_watch.c +++ b/sapi/phpdbg/phpdbg_watch.c @@ -306,6 +306,9 @@ int phpdbg_watchpoint_segfault_handler(siginfo_t *info, void *context) { } #ifdef HAVE_USERFAULTFD_WRITEFAULT +# if defined(__GNUC__) && !defined(__clang__) +__attribute__((no_sanitize_address)) +# endif void *phpdbg_watchpoint_userfaultfd_thread(void *phpdbg_globals) { pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL); zend_phpdbg_globals *globals = (zend_phpdbg_globals *) phpdbg_globals;