2006-02-27 22:46:30

by Chris Wright

[permalink] [raw]
Subject: [patch 11/39] [PATCH] sys_signal: initialize ->sa_mask

-stable review patch. If anyone has any objections, please let us know.
------------------

Pointed out by Linus Torvalds.

sys_signal() forgets to initialize ->sa_mask.

( I suspect arch/ia64/ia32/ia32_signal.c:sys32_signal()
also needs this fix )

Signed-off-by: Oleg Nesterov <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Signed-off-by: Chris Wright <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---

kernel/signal.c | 1 +
1 files changed, 1 insertion(+)

--- linux-2.6.15.4.orig/kernel/signal.c
+++ linux-2.6.15.4/kernel/signal.c
@@ -2604,6 +2604,7 @@ sys_signal(int sig, __sighandler_t handl

new_sa.sa.sa_handler = handler;
new_sa.sa.sa_flags = SA_ONESHOT | SA_NOMASK;
+ sigemptyset(&new_sa.sa.sa_mask);

ret = do_sigaction(sig, &new_sa, &old_sa);


--