[PATCH resend #1] Handle SA_NODEFER correctly for i386

From: Jörn Engel
Date: Thu Aug 21 2003 - 13:09:31 EST


Hi Linus!

This fixes i386 to only ignore the current signal wir SA_NODEFER set.
All other architectures (except m68k, funny enough) need the same fix,
but I'm lazy today.

Joern

--- linux-2.5.73/arch/i386/kernel/signal.c~sigmask_i386 2003-07-04 18:59:48.000000000 +0200
+++ linux-2.5.73/arch/i386/kernel/signal.c 2003-07-04 22:39:59.000000000 +0200
@@ -551,13 +551,12 @@
if (ka->sa.sa_flags & SA_ONESHOT)
ka->sa.sa_handler = SIG_DFL;

- if (!(ka->sa.sa_flags & SA_NODEFER)) {
- spin_lock_irq(&current->sighand->siglock);
- sigorsets(&current->blocked,&current->blocked,&ka->sa.sa_mask);
+ spin_lock_irq(&current->sighand->siglock);
+ sigorsets(&current->blocked,&current->blocked,&ka->sa.sa_mask);
+ if (!(ka->sa.sa_flags & SA_NODEFER))
sigaddset(&current->blocked,sig);
- recalc_sigpending();
- spin_unlock_irq(&current->sighand->siglock);
- }
+ recalc_sigpending();
+ spin_unlock_irq(&current->sighand->siglock);
}

/*
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/