From 094d2b0ea825865bfc076b6667db6973d673385c Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Tue, 20 Jun 2000 18:31:04 +0000 Subject: [PATCH] (sigblock, sigunblock) [USG5_4]: Set sigprocmask_set, and pass a pointer to it to sigprocmask. --- src/syssignal.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/syssignal.h b/src/syssignal.h index 66e6ffa61fc..26e10edd5b9 100644 --- a/src/syssignal.h +++ b/src/syssignal.h @@ -78,11 +78,17 @@ sigset_t sys_sigsetmask P_ ((sigset_t new_mask)); #else /* ! defined (POSIX_SIGNALS) */ #ifdef USG5_4 +extern SIGMASKTYPE sigprocmask_set; + #ifndef sigblock -#define sigblock(sig) (sigprocmask (SIG_BLOCK, SIGEMPTYMASK | sig, NULL)) +#define sigblock(sig) \ + (sigprocmask_set = SIGEMPTYMASK | (sig), \ + sigprocmask (SIG_BLOCK, &sigprocmask_set, NULL)) #endif -#define sigunblock(sig) (sigprocmask (SIG_SETMASK, SIGFULLMASK & ~(sig), NULL)) +#define sigunblock(sig) \ + (sigprocmask_set = SIGFULLMASK & ~(sig), \ + sigprocmask (SIG_SETMASK, &sigprocmask_set, NULL)) #else #ifdef USG -- 2.39.2