diff options
-rw-r--r-- | kernel/exit.c | 8 | ||||
-rw-r--r-- | kernel/signal.c | 4 |
2 files changed, 2 insertions, 10 deletions
diff --git a/kernel/exit.c b/kernel/exit.c index 464c2b172f07..9578c1ae19ca 100644 --- a/kernel/exit.c +++ b/kernel/exit.c | |||
@@ -813,7 +813,7 @@ static void exit_notify(struct task_struct *tsk) | |||
813 | __kill_pgrp_info(SIGCONT, SEND_SIG_PRIV, pgrp); | 813 | __kill_pgrp_info(SIGCONT, SEND_SIG_PRIV, pgrp); |
814 | } | 814 | } |
815 | 815 | ||
816 | /* Let father know we died | 816 | /* Let father know we died |
817 | * | 817 | * |
818 | * Thread signals are configurable, but you aren't going to use | 818 | * Thread signals are configurable, but you aren't going to use |
819 | * that to send signals to arbitary processes. | 819 | * that to send signals to arbitary processes. |
@@ -826,9 +826,7 @@ static void exit_notify(struct task_struct *tsk) | |||
826 | * If our self_exec id doesn't match our parent_exec_id then | 826 | * If our self_exec id doesn't match our parent_exec_id then |
827 | * we have changed execution domain as these two values started | 827 | * we have changed execution domain as these two values started |
828 | * the same after a fork. | 828 | * the same after a fork. |
829 | * | ||
830 | */ | 829 | */ |
831 | |||
832 | if (tsk->exit_signal != SIGCHLD && tsk->exit_signal != -1 && | 830 | if (tsk->exit_signal != SIGCHLD && tsk->exit_signal != -1 && |
833 | ( tsk->parent_exec_id != t->self_exec_id || | 831 | ( tsk->parent_exec_id != t->self_exec_id || |
834 | tsk->self_exec_id != tsk->parent_exec_id) | 832 | tsk->self_exec_id != tsk->parent_exec_id) |
@@ -848,9 +846,7 @@ static void exit_notify(struct task_struct *tsk) | |||
848 | } | 846 | } |
849 | 847 | ||
850 | state = EXIT_ZOMBIE; | 848 | state = EXIT_ZOMBIE; |
851 | if (tsk->exit_signal == -1 && | 849 | if (tsk->exit_signal == -1 && likely(!tsk->ptrace)) |
852 | (likely(tsk->ptrace == 0) || | ||
853 | unlikely(tsk->parent->signal->flags & SIGNAL_GROUP_EXIT))) | ||
854 | state = EXIT_DEAD; | 850 | state = EXIT_DEAD; |
855 | tsk->exit_state = state; | 851 | tsk->exit_state = state; |
856 | 852 | ||
diff --git a/kernel/signal.c b/kernel/signal.c index ef8156a6aad5..b27c01a66448 100644 --- a/kernel/signal.c +++ b/kernel/signal.c | |||
@@ -1561,10 +1561,6 @@ static inline int may_ptrace_stop(void) | |||
1561 | (current->ptrace & PT_ATTACHED))) | 1561 | (current->ptrace & PT_ATTACHED))) |
1562 | return 0; | 1562 | return 0; |
1563 | 1563 | ||
1564 | if (unlikely(current->signal == current->parent->signal) && | ||
1565 | unlikely(current->signal->flags & SIGNAL_GROUP_EXIT)) | ||
1566 | return 0; | ||
1567 | |||
1568 | /* | 1564 | /* |
1569 | * Are we in the middle of do_coredump? | 1565 | * Are we in the middle of do_coredump? |
1570 | * If so and our tracer is also part of the coredump stopping | 1566 | * If so and our tracer is also part of the coredump stopping |