summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--signal.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/signal.c b/signal.c
index 3932e97d27..636574ba07 100644
--- a/signal.c
+++ b/signal.c
@@ -872,9 +872,9 @@ check_stack_overflow(int sig, const void *addr)
# else
# define FAULT_ADDRESS info->si_addr
# ifdef USE_UCONTEXT_REG
-# define CHECK_STACK_OVERFLOW() check_stack_overflow(sig, (uintptr_t)FAULT_ADDRESS, ctx)
+# define CHECK_STACK_OVERFLOW() (info->si_pid ? (void)0 : check_stack_overflow(sig, (uintptr_t)FAULT_ADDRESS, ctx))
# else
-# define CHECK_STACK_OVERFLOW() check_stack_overflow(sig, FAULT_ADDRESS)
+# define CHECK_STACK_OVERFLOW() (info->si_pid ? (void)0 : check_stack_overflow(sig, FAULT_ADDRESS))
# endif
# define MESSAGE_FAULT_ADDRESS " at %p", FAULT_ADDRESS
# endif