fix omission that kept sa_restorer from being used
authorRich Felker <dalias@aerifal.cx>
Sun, 13 Feb 2011 21:46:33 +0000 (16:46 -0500)
committerRich Felker <dalias@aerifal.cx>
Sun, 13 Feb 2011 21:46:33 +0000 (16:46 -0500)
include/bits/signal.h
src/signal/sigaction.c

index 2427f37a59ecd7c3fb651d66a48898fdb8f6b5be..c0bb818b0e12cf33d01a86991d65ed1d623a91f1 100644 (file)
@@ -48,6 +48,7 @@ struct __siginfo
 #define SA_RESTART    0x10000000
 #define SA_NODEFER    0x40000000
 #define SA_RESETHAND  0x80000000
+#define SA_RESTORER   0x04000000
 
 #define SS_ONSTACK    1
 #define SS_DISABLE    2
index 4acd1730bd8dd17c9951c4f0db4295fa0b123321..9a362262174c8838f52f7bf9d7023f0aeec445ce 100644 (file)
@@ -20,7 +20,7 @@ int __libc_sigaction(int sig, const struct sigaction *sa, struct sigaction *old)
        long pksa=0, pkold=0;
        if (sa) {
                ksa.handler = sa->sa_handler;
-               ksa.flags = sa->sa_flags;
+               ksa.flags = sa->sa_flags | SA_RESTORER;
                ksa.restorer = restorer;
                ksa.mask = sa->sa_mask;
                pksa = (long)&ksa;