diff options
author | Carmelo Amoroso <carmelo.amoroso@st.com> | 2008-12-03 14:04:03 +0000 |
---|---|---|
committer | Carmelo Amoroso <carmelo.amoroso@st.com> | 2008-12-03 14:04:03 +0000 |
commit | d5c32667ad11ff38dc46be527266297b38a341d1 (patch) | |
tree | b3ce68f179d97e6e25e5c8e7ace845c4a561322b /libc/signal/sysv_signal.c | |
parent | 329ef3196b396a70eecd5a4789845d368b488ab7 (diff) | |
download | uClibc-alpine-d5c32667ad11ff38dc46be527266297b38a341d1.tar.bz2 uClibc-alpine-d5c32667ad11ff38dc46be527266297b38a341d1.tar.xz |
Synch with trunk @ 24242
Step 18: some more synch: hidden_proto, size reduction
and signal handling changes.
Diffstat (limited to 'libc/signal/sysv_signal.c')
-rw-r--r-- | libc/signal/sysv_signal.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/libc/signal/sysv_signal.c b/libc/signal/sysv_signal.c index c0cd19a95..118094b27 100644 --- a/libc/signal/sysv_signal.c +++ b/libc/signal/sysv_signal.c @@ -47,10 +47,9 @@ __sighandler_t __sysv_signal (int sig, __sighandler_t handler) } act.sa_handler = handler; - if (__sigemptyset (&act.sa_mask) < 0) - return SIG_ERR; - act.sa_flags = SA_ONESHOT | SA_NOMASK | SA_INTERRUPT; - act.sa_flags &= ~SA_RESTART; + __sigemptyset (&act.sa_mask); + act.sa_flags = (SA_ONESHOT | SA_NOMASK | SA_INTERRUPT) & ~SA_RESTART; + /* In Linux (as of 2.6.25), fails only if sig is SIGKILL or SIGSTOP */ if (sigaction (sig, &act, &oact) < 0) return SIG_ERR; |