patch-1.3.9 linux/kernel/signal.c

Next file: linux/lib/Makefile
Previous file: linux/kernel/ksyms.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.8/linux/kernel/signal.c linux/kernel/signal.c
@@ -147,12 +147,10 @@
 		if (err)
 			return err;
 		memcpy_fromfs(&new_sa, action, sizeof(struct sigaction));
+		new_sa.sa_mask |= _S(signum);
 		if (new_sa.sa_flags & SA_NOMASK)
-			new_sa.sa_mask = 0;
-		else {
-			new_sa.sa_mask |= _S(signum);
-			new_sa.sa_mask &= _BLOCKABLE;
-		}
+			new_sa.sa_mask &= ~_S(signum);
+		new_sa.sa_mask &= _BLOCKABLE;
 		if (new_sa.sa_handler != SIG_DFL && new_sa.sa_handler != SIG_IGN) {
 			err = verify_area(VERIFY_READ, new_sa.sa_handler, 1);
 			if (err)

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this