diff options
-rw-r--r-- | kernel/signal.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/kernel/signal.c b/kernel/signal.c index 05853a7337e3..fb5da6d19f14 100644 --- a/kernel/signal.c +++ b/kernel/signal.c | |||
@@ -417,9 +417,8 @@ static int collect_signal(int sig, struct sigpending *list, siginfo_t *info) | |||
417 | static int __dequeue_signal(struct sigpending *pending, sigset_t *mask, | 417 | static int __dequeue_signal(struct sigpending *pending, sigset_t *mask, |
418 | siginfo_t *info) | 418 | siginfo_t *info) |
419 | { | 419 | { |
420 | int sig = 0; | 420 | int sig = next_signal(pending, mask); |
421 | 421 | ||
422 | sig = next_signal(pending, mask); | ||
423 | if (sig) { | 422 | if (sig) { |
424 | if (current->notifier) { | 423 | if (current->notifier) { |
425 | if (sigismember(current->notifier_mask, sig)) { | 424 | if (sigismember(current->notifier_mask, sig)) { |
@@ -432,9 +431,7 @@ static int __dequeue_signal(struct sigpending *pending, sigset_t *mask, | |||
432 | 431 | ||
433 | if (!collect_signal(sig, pending, info)) | 432 | if (!collect_signal(sig, pending, info)) |
434 | sig = 0; | 433 | sig = 0; |
435 | |||
436 | } | 434 | } |
437 | recalc_sigpending(); | ||
438 | 435 | ||
439 | return sig; | 436 | return sig; |
440 | } | 437 | } |
@@ -451,6 +448,7 @@ int dequeue_signal(struct task_struct *tsk, sigset_t *mask, siginfo_t *info) | |||
451 | if (!signr) | 448 | if (!signr) |
452 | signr = __dequeue_signal(&tsk->signal->shared_pending, | 449 | signr = __dequeue_signal(&tsk->signal->shared_pending, |
453 | mask, info); | 450 | mask, info); |
451 | recalc_sigpending_tsk(tsk); | ||
454 | if (signr && unlikely(sig_kernel_stop(signr))) { | 452 | if (signr && unlikely(sig_kernel_stop(signr))) { |
455 | /* | 453 | /* |
456 | * Set a marker that we have dequeued a stop signal. Our | 454 | * Set a marker that we have dequeued a stop signal. Our |