From 1f91fd381ed493319274fdbbc474e6113d7f6f82 Mon Sep 17 00:00:00 2001 From: Bob Weinand Date: Wed, 4 Jan 2023 15:22:57 +0100 Subject: [PATCH] Properly forward the signal to the original handler if TSRM is shutdown. This ensures proper handling of SIGQUIT in ZTS fpm builds outside of active requests. --- Zend/zend_signal.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Zend/zend_signal.c b/Zend/zend_signal.c index 0990999e0116a..e32ffeff9c6b6 100644 --- a/Zend/zend_signal.c +++ b/Zend/zend_signal.c @@ -183,8 +183,7 @@ static void zend_signal_handler(int signo, siginfo_t *siginfo, void *context) zend_signal_entry_t p_sig; #ifdef ZTS if (tsrm_is_shutdown() || !tsrm_get_ls_cache()) { - p_sig.flags = 0; - p_sig.handler = SIG_DFL; + p_sig = global_orig_handlers[signo-1]; } else #endif p_sig = SIGG(handlers)[signo-1];