Subject: kern/30348: sigwait doesn't get signals from pthread_kill
To: None <kern-bug-people@netbsd.org, gnats-admin@netbsd.org,>
From: None <nb-pr@gendalia.org>
List: netbsd-bugs
Date: 05/27/2005 04:31:00
>Number:         30348
>Category:       kern
>Synopsis:       sigwait doesn't get signals from pthread_kill
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri May 27 04:31:00 +0000 2005
>Originator:     Tracy J. Di Marco White
>Release:        NetBSD 2.0
>Organization:
TNF
>Environment:
	
	
System: NetBSD bender.jdwhite.org 2.0 NetBSD 2.0 (BENDER) #8: Mon Nov 29 20:52:24 CST 2004 gendalia@satai:/usr/obj/i386/BENDER i386
Architecture: i386
Machine: i386
>Description:
From work on OpenAFS, fileserver receives SIGQUIT, but sigwait never
cleans up and exits.  This is beause sigwait doesn't get signals from
pthread_kill.
>How-To-Repeat:
pkgsrc/net/openafs
src/util/softsig.c:

"bos restart fileserver"

>Fix:
comment from softsig.c:
/*------------------------------------------------------------------------
 * Under Darwin 6.x (including 7.0), sigwait() is broken, so we use
 * sigsuspend() instead.  We also don't block signals we don't know
 * about, so they should kill us, rather than us returning zero status.
 *------------------------------------------------------------------------*/

setting the same defines as for Darwin make things work correctly.