summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2015-10-10 16:42:29 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2015-10-10 16:42:29 +0200
commit08d8159d5a960466bb9a951ecc8036baa4d74e6b (patch)
tree949251fd7c950335318f8a6363148b02944be3ed
parentdc28c9c42afb66c751c894ab923917e9bda93adc (diff)
Fix pthread_kill
* sysdeps/hurd/pt-kill.c (pthread_kill): Lock ss lock before calling _hurd_raise_signal. Return error returned by _hurd_raise_signal.
-rw-r--r--sysdeps/hurd/pt-kill.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sysdeps/hurd/pt-kill.c b/sysdeps/hurd/pt-kill.c
index d204e3f..49dfd7d 100644
--- a/sysdeps/hurd/pt-kill.c
+++ b/sysdeps/hurd/pt-kill.c
@@ -46,7 +46,6 @@ pthread_kill (pthread_t thread, int sig)
detail.code = sig;
detail.error = 0;
- _hurd_raise_signal (ss, sig, &detail);
-
- return 0;
+ __spin_lock (&ss->lock);
+ return _hurd_raise_signal (ss, sig, &detail);
}