diff options
author | marcel <marcel@FreeBSD.org> | 1999-10-10 09:14:31 +0000 |
---|---|---|
committer | marcel <marcel@FreeBSD.org> | 1999-10-10 09:14:31 +0000 |
commit | 41164989a7ea1c4b6e42ef2bea639d575cc3224d (patch) | |
tree | 59437ca35e9e351a8c2728c508c965750709b227 /sys | |
parent | bcf55ab2b8330859798393d6d66802ad0661dafd (diff) | |
download | FreeBSD-src-41164989a7ea1c4b6e42ef2bea639d575cc3224d.zip FreeBSD-src-41164989a7ea1c4b6e42ef2bea639d575cc3224d.tar.gz |
Avoid using the osig* syscalls.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/i386/ibcs2/ibcs2_signal.c | 49 |
1 files changed, 28 insertions, 21 deletions
diff --git a/sys/i386/ibcs2/ibcs2_signal.c b/sys/i386/ibcs2/ibcs2_signal.c index 8aacade..f8829f1 100644 --- a/sys/i386/ibcs2/ibcs2_signal.c +++ b/sys/i386/ibcs2/ibcs2_signal.c @@ -265,11 +265,15 @@ ibcs2_sigsys(p, uap) case IBCS2_SIGHOLD_MASK: { - struct osigprocmask_args sa; + sigset_t mask; + struct sigprocmask_args sa; + SIGEMPTYSET(mask); + SIGADDSET(mask, signum); SCARG(&sa, how) = SIG_BLOCK; - SCARG(&sa, mask) = sigmask(signum); - return osigprocmask(p, &sa); + SCARG(&sa, set) = &mask; + SCARG(&sa, oset) = NULL; + return sigprocmask(p, &sa); } case IBCS2_SIGNAL_MASK: @@ -327,11 +331,15 @@ ibcs2_sigsys(p, uap) case IBCS2_SIGRELSE_MASK: { - struct osigprocmask_args sa; + sigset_t mask; + struct sigprocmask_args sa; + SIGEMPTYSET(mask); + SIGADDSET(mask, signum); SCARG(&sa, how) = SIG_UNBLOCK; - SCARG(&sa, mask) = sigmask(signum); - return osigprocmask(p, &sa); + SCARG(&sa, set) = &mask; + SCARG(&sa, oset) = NULL; + return sigprocmask(p, &sa); } case IBCS2_SIGIGNORE_MASK: @@ -358,12 +366,13 @@ ibcs2_sigsys(p, uap) case IBCS2_SIGPAUSE_MASK: { - osigset_t mask; - struct osigsuspend_args sa; + sigset_t mask; + struct sigsuspend_args sa; - SIG2OSIG(p->p_sigmask, mask); - SCARG(&sa, mask) = mask &~ sigmask(signum); - return osigsuspend(p, &sa); + mask = p->p_sigmask; + SIGDELSET(mask, signum); + SCARG(&sa, sigmask) = &mask; + return sigsuspend(p, &sa); } default: @@ -445,17 +454,15 @@ ibcs2_sigsuspend(p, uap) { ibcs2_sigset_t sss; sigset_t bss; - osigset_t mask; - struct osigsuspend_args sa; + struct sigsuspend_args sa; int error; if ((error = copyin(SCARG(uap, mask), &sss, sizeof(sss))) != 0) return error; ibcs2_to_bsd_sigset(&sss, &bss); - SIG2OSIG(bss, mask); - SCARG(&sa, mask) = mask; - return osigsuspend(p, &sa); + SCARG(&sa, sigmask) = &bss; + return sigsuspend(p, &sa); } int @@ -463,12 +470,12 @@ ibcs2_pause(p, uap) register struct proc *p; struct ibcs2_pause_args *uap; { - struct osigsuspend_args bsa; - osigset_t mask; + sigset_t mask; + struct sigsuspend_args sa; - SIG2OSIG(p->p_sigmask, mask); - SCARG(&bsa, mask) = mask; - return osigsuspend(p, &bsa); + mask = p->p_sigmask; + SCARG(&sa, sigmask) = &mask; + return sigsuspend(p, &sa); } int |