diff options
Diffstat (limited to 'kernel/signal.c')
-rw-r--r-- | kernel/signal.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/kernel/signal.c b/kernel/signal.c index 97e575a3387e..0f3370872506 100644 --- a/kernel/signal.c +++ b/kernel/signal.c | |||
@@ -1592,7 +1592,7 @@ int do_notify_parent(struct task_struct *tsk, int sig) | |||
1592 | /* do_notify_parent_cldstop should have been called instead. */ | 1592 | /* do_notify_parent_cldstop should have been called instead. */ |
1593 | BUG_ON(task_is_stopped_or_traced(tsk)); | 1593 | BUG_ON(task_is_stopped_or_traced(tsk)); |
1594 | 1594 | ||
1595 | BUG_ON(!task_ptrace(tsk) && | 1595 | BUG_ON(!tsk->ptrace && |
1596 | (tsk->group_leader != tsk || !thread_group_empty(tsk))); | 1596 | (tsk->group_leader != tsk || !thread_group_empty(tsk))); |
1597 | 1597 | ||
1598 | info.si_signo = sig; | 1598 | info.si_signo = sig; |
@@ -1631,7 +1631,7 @@ int do_notify_parent(struct task_struct *tsk, int sig) | |||
1631 | 1631 | ||
1632 | psig = tsk->parent->sighand; | 1632 | psig = tsk->parent->sighand; |
1633 | spin_lock_irqsave(&psig->siglock, flags); | 1633 | spin_lock_irqsave(&psig->siglock, flags); |
1634 | if (!task_ptrace(tsk) && sig == SIGCHLD && | 1634 | if (!tsk->ptrace && sig == SIGCHLD && |
1635 | (psig->action[SIGCHLD-1].sa.sa_handler == SIG_IGN || | 1635 | (psig->action[SIGCHLD-1].sa.sa_handler == SIG_IGN || |
1636 | (psig->action[SIGCHLD-1].sa.sa_flags & SA_NOCLDWAIT))) { | 1636 | (psig->action[SIGCHLD-1].sa.sa_flags & SA_NOCLDWAIT))) { |
1637 | /* | 1637 | /* |
@@ -1731,7 +1731,7 @@ static void do_notify_parent_cldstop(struct task_struct *tsk, | |||
1731 | 1731 | ||
1732 | static inline int may_ptrace_stop(void) | 1732 | static inline int may_ptrace_stop(void) |
1733 | { | 1733 | { |
1734 | if (!likely(task_ptrace(current))) | 1734 | if (!likely(current->ptrace)) |
1735 | return 0; | 1735 | return 0; |
1736 | /* | 1736 | /* |
1737 | * Are we in the middle of do_coredump? | 1737 | * Are we in the middle of do_coredump? |
@@ -1989,7 +1989,7 @@ static bool do_signal_stop(int signr) | |||
1989 | if (!(sig->flags & SIGNAL_STOP_STOPPED)) | 1989 | if (!(sig->flags & SIGNAL_STOP_STOPPED)) |
1990 | sig->group_exit_code = signr; | 1990 | sig->group_exit_code = signr; |
1991 | else | 1991 | else |
1992 | WARN_ON_ONCE(!task_ptrace(current)); | 1992 | WARN_ON_ONCE(!current->ptrace); |
1993 | 1993 | ||
1994 | sig->group_stop_count = 0; | 1994 | sig->group_stop_count = 0; |
1995 | 1995 | ||
@@ -2014,7 +2014,7 @@ static bool do_signal_stop(int signr) | |||
2014 | } | 2014 | } |
2015 | } | 2015 | } |
2016 | 2016 | ||
2017 | if (likely(!task_ptrace(current))) { | 2017 | if (likely(!current->ptrace)) { |
2018 | int notify = 0; | 2018 | int notify = 0; |
2019 | 2019 | ||
2020 | /* | 2020 | /* |
@@ -2093,7 +2093,7 @@ static void do_jobctl_trap(void) | |||
2093 | static int ptrace_signal(int signr, siginfo_t *info, | 2093 | static int ptrace_signal(int signr, siginfo_t *info, |
2094 | struct pt_regs *regs, void *cookie) | 2094 | struct pt_regs *regs, void *cookie) |
2095 | { | 2095 | { |
2096 | if (!task_ptrace(current)) | 2096 | if (!current->ptrace) |
2097 | return signr; | 2097 | return signr; |
2098 | 2098 | ||
2099 | ptrace_signal_deliver(regs, cookie); | 2099 | ptrace_signal_deliver(regs, cookie); |
@@ -2179,7 +2179,7 @@ relock: | |||
2179 | do_notify_parent_cldstop(current, false, why); | 2179 | do_notify_parent_cldstop(current, false, why); |
2180 | 2180 | ||
2181 | leader = current->group_leader; | 2181 | leader = current->group_leader; |
2182 | if (task_ptrace(leader) && !real_parent_is_ptracer(leader)) | 2182 | if (leader->ptrace && !real_parent_is_ptracer(leader)) |
2183 | do_notify_parent_cldstop(leader, true, why); | 2183 | do_notify_parent_cldstop(leader, true, why); |
2184 | 2184 | ||
2185 | read_unlock(&tasklist_lock); | 2185 | read_unlock(&tasklist_lock); |