summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorgallatin <gallatin@FreeBSD.org>2000-11-16 02:07:05 +0000
committergallatin <gallatin@FreeBSD.org>2000-11-16 02:07:05 +0000
commit5941c7f45db13c86fe34577d9cbbe6fb99542680 (patch)
tree0719e2795dcd249d69994b13e13e5cb840645801 /sys
parent5fa45f43dd5c678ed2869cb3f64590fde4a0bf63 (diff)
downloadFreeBSD-src-5941c7f45db13c86fe34577d9cbbe6fb99542680.zip
FreeBSD-src-5941c7f45db13c86fe34577d9cbbe6fb99542680.tar.gz
fix glaring bugs in rt signals -- copyout the right signal mask in
linux_rt_sendsig() and restore the same signal mask linux does in rt_sigreturn(). This gets us saving/restoring all 64-bits of the linux sigset_t in rt signals. Reviewed by: marcel
Diffstat (limited to 'sys')
-rw-r--r--sys/i386/linux/linux_sysvec.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/i386/linux/linux_sysvec.c b/sys/i386/linux/linux_sysvec.c
index 895a48c..d86db5b 100644
--- a/sys/i386/linux/linux_sysvec.c
+++ b/sys/i386/linux/linux_sysvec.c
@@ -56,6 +56,7 @@
#include <i386/linux/linux.h>
#include <i386/linux/linux_proto.h>
+#include <compat/linux/linux_signal.h>
#include <compat/linux/linux_util.h>
MODULE_VERSION(linux, 1);
@@ -300,7 +301,7 @@ linux_rt_sendsig(sig_t catcher, int sig, sigset_t *mask, u_long code)
(long)p->p_pid, frame.sf_sc.uc_stack.ss_flags, p->p_sigstk.ss_sp,
p->p_sigstk.ss_size, frame.sf_sc.uc_mcontext.sc_mask);
#endif
- bsd_to_linux_sigset(&p->p_sigmask, &frame.sf_sc.uc_sigmask);
+ bsd_to_linux_sigset(mask, &frame.sf_sc.uc_sigmask);
if (copyout(&frame, fp, sizeof(frame)) != 0) {
/*
@@ -621,7 +622,7 @@ linux_rt_sigreturn(p, args)
}
p->p_sigstk.ss_flags &= ~SS_ONSTACK;
- SIGSETOLD(p->p_sigmask, context->sc_mask);
+ linux_to_bsd_sigset(&uc.uc_sigmask, &p->p_sigmask);
SIG_CANTMASK(p->p_sigmask);
/*
OpenPOWER on IntegriCloud