diff options
author | 2012-04-13 19:20:31 +0000 | |
---|---|---|
committer | 2012-04-13 19:20:31 +0000 | |
commit | 1f60859d7044e0a3cb65a2e366b37a0bcb10cd90 (patch) | |
tree | 44953197f3448d9d13ecf140677f769ecc9d26c5 /sys/kern/sys_process.c | |
parent | Don't convert a mbuf to a cluster and think the data in the mbuf is still (diff) | |
download | wireguard-openbsd-1f60859d7044e0a3cb65a2e366b37a0bcb10cd90.tar.xz wireguard-openbsd-1f60859d7044e0a3cb65a2e366b37a0bcb10cd90.zip |
For now, direct the kill signal sent by PT_KILL to the thread that made us
stop, just like we do for PT_CONTINUE/PT_STEP. The current code isn't
ready for directing signals to other threads yet.
Diffstat (limited to 'sys/kern/sys_process.c')
-rw-r--r-- | sys/kern/sys_process.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/kern/sys_process.c b/sys/kern/sys_process.c index 14a19211c0a..b36da4fb13d 100644 --- a/sys/kern/sys_process.c +++ b/sys/kern/sys_process.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sys_process.c,v 1.56 2012/04/13 16:37:51 kettenis Exp $ */ +/* $OpenBSD: sys_process.c,v 1.57 2012/04/13 19:20:31 kettenis Exp $ */ /* $NetBSD: sys_process.c,v 1.55 1996/05/15 06:17:47 tls Exp $ */ /*- @@ -519,6 +519,9 @@ sys_ptrace(struct proc *p, void *v, register_t *retval) return (error); case PT_KILL: + if (SCARG(uap, pid) < THREAD_PID_OFFSET && tr->ps_single) + t = tr->ps_single; + /* just send the process a KILL signal. */ SCARG(uap, data) = SIGKILL; goto sendsig; /* in PT_CONTINUE, above. */ |