bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 11/15] Hurd signals: fix sigwait() for global signals


From: Samuel Thibault
Subject: Re: [PATCH 11/15] Hurd signals: fix sigwait() for global signals
Date: Sun, 3 Jul 2011 02:32:00 +0200
User-agent: Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30)

Jeremie Koenig, le Wed 29 Jun 2011 18:30:23 +0200, a écrit :
> * sysdeps/mach/hurd/sigwait.c (__sigwait): Change the blocking mask
> temporarily so that we catch global as well as thread-specific signals.

Mmm, this is unsafe: if yet another signal arrives between the
setjmp return and locking ss, it will be processed instead of being
blocked.

I know from experience that sigwait is a pain to implement correctly,
especially with threads with global signals, since you're supposed to
either deliver the global signal to some thread which doesn't block it,
or wake a thread which is waiting for it in sigwait...

Samuel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]