summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2009-10-18 00:24:19 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2009-10-18 00:24:19 +0200
commitfb30b6bbf28d91667dcb9691dfeefffac4f99b82 (patch)
tree76aba56dedc609ceffb1d62da49ac912e3b046e2
parentd69e38ee77536912308212945cfb0b6abe93cef0 (diff)
Fix pthread_kill(thread, 0)
* sysdeps/hurd/pt-kill.c (pthread_kill): Return immediately after checks without calling _hurd_raise_signal if sig is 0.
-rw-r--r--sysdeps/hurd/pt-kill.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sysdeps/hurd/pt-kill.c b/sysdeps/hurd/pt-kill.c
index f970e06..d204e3f 100644
--- a/sysdeps/hurd/pt-kill.c
+++ b/sysdeps/hurd/pt-kill.c
@@ -39,6 +39,9 @@ pthread_kill (pthread_t thread, int sig)
ss = _hurd_thread_sigstate (pthread->kernel_thread);
assert (ss);
+ if (!sig)
+ return 0;
+
detail.exc = 0;
detail.code = sig;
detail.error = 0;