summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/sigproc.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2005-08-25 03:12:48 +0000
committerChristopher Faylor <me@cgf.cx>2005-08-25 03:12:48 +0000
commitb9ebff640a76197a91b086a9aff4a6db53cc9d4b (patch)
tree26e625c9d0e4b4ac28456ccf971593d1f4ece985 /winsup/cygwin/sigproc.cc
parent5092e4a714467dc7ee86a8bc33168ed8d66ce5cb (diff)
downloadcygnal-b9ebff640a76197a91b086a9aff4a6db53cc9d4b.tar.gz
cygnal-b9ebff640a76197a91b086a9aff4a6db53cc9d4b.tar.bz2
cygnal-b9ebff640a76197a91b086a9aff4a6db53cc9d4b.zip
* exceptions.cc (handle_sigsuspend): Just sleep forever if called from non-main
thread. (sigpacket:process): Simplify logic which determines when and how a signal is masked. Don't trigger sigwait if there is a signal handler. * sigproc.cc (wait_sig): Update comment. Try to process a signal which is in the queue if it isn't queued for the target thread (this is still not right).
Diffstat (limited to 'winsup/cygwin/sigproc.cc')
-rw-r--r--winsup/cygwin/sigproc.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/winsup/cygwin/sigproc.cc b/winsup/cygwin/sigproc.cc
index 2bb9d4eda..382b226f8 100644
--- a/winsup/cygwin/sigproc.cc
+++ b/winsup/cygwin/sigproc.cc
@@ -1097,9 +1097,10 @@ wait_sig (VOID *self)
else
{
int sig = pack.si.si_signo;
- // FIXME: Not quite right when taking threads into consideration.
- // Do we need a per-thread queue?
- if (sigq.sigs[sig].si.si_signo)
+ // FIXME: REALLY not right when taking threads into consideration.
+ // We need a per-thread queue since each thread can have its own
+ // list of blocked signals. CGF 2005-08-24
+ if (sigq.sigs[sig].si.si_signo && sigq.sigs[sig].tls == pack.tls)
sigproc_printf ("sig %d already queued", pack.si.si_signo);
else
{