Module Name: src Committed By: christos Date: Tue Aug 30 22:45:56 UTC 2011
Modified Files: src/sys/kern: sys_process.c Log Message: Process the signal now, otherwise calling issignal() and ignoring the return will lose the signal if it came from the debugger (issignal() clears p->p_xstat) To generate a diff of this commit: cvs rdiff -u -r1.158 -r1.159 src/sys/kern/sys_process.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/kern/sys_process.c diff -u src/sys/kern/sys_process.c:1.158 src/sys/kern/sys_process.c:1.159 --- src/sys/kern/sys_process.c:1.158 Mon Aug 29 13:31:50 2011 +++ src/sys/kern/sys_process.c Tue Aug 30 18:45:55 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: sys_process.c,v 1.158 2011/08/29 17:31:50 jmcneill Exp $ */ +/* $NetBSD: sys_process.c,v 1.159 2011/08/30 22:45:55 christos Exp $ */ /*- * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc. @@ -118,7 +118,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: sys_process.c,v 1.158 2011/08/29 17:31:50 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sys_process.c,v 1.159 2011/08/30 22:45:55 christos Exp $"); #include "opt_ptrace.h" #include "opt_ktrace.h" @@ -1051,6 +1051,7 @@ { struct lwp *l = curlwp; struct proc *p = l->l_proc, *pp; + int sig; mutex_enter(proc_lock); mutex_enter(p->p_lock); @@ -1072,7 +1073,8 @@ * from userret(). */ KERNEL_UNLOCK_ALL(l, &l->l_biglocks); - (void)issignal(l); + if ((sig = issignal(l)) != 0) + postsig(sig); mutex_exit(p->p_lock); KERNEL_LOCK(l->l_biglocks, l); }