From 137cf33d5e6d78f173f70f818abca937b43f8c85 Mon Sep 17 00:00:00 2001 From: David Xu Date: Wed, 1 Sep 2010 01:26:07 +0000 Subject: [PATCH] rescure comments from RELENG_4. --- sys/kern/kern_sig.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c index 9cbbe8d6c978..f54d59e59f2b 100644 --- a/sys/kern/kern_sig.c +++ b/sys/kern/kern_sig.c @@ -2140,6 +2140,10 @@ tdsendsignal(struct proc *p, struct thread *td, int sig, ksiginfo_t *ksi) */ if (P_SHOULDSTOP(p)) { if (sig == SIGKILL) { + /* + * If traced process is already stopped, + * then no further action is necessary. + */ if (p->p_flag & P_TRACED) goto out; /* @@ -2152,6 +2156,10 @@ tdsendsignal(struct proc *p, struct thread *td, int sig, ksiginfo_t *ksi) } if (prop & SA_CONT) { + /* + * If traced process is already stopped, + * then no further action is necessary. + */ if (p->p_flag & P_TRACED) goto out; /* @@ -2198,6 +2206,10 @@ tdsendsignal(struct proc *p, struct thread *td, int sig, ksiginfo_t *ksi) } if (prop & SA_STOP) { + /* + * If traced process is already stopped, + * then no further action is necessary. + */ if (p->p_flag & P_TRACED) goto out; /*