about summary refs log tree commit diff
path: root/src/thread/pthread_kill.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2011-03-19 23:18:34 -0400
committerRich Felker <dalias@aerifal.cx>2011-03-19 23:18:34 -0400
commitbe82e122bf37fdcd1766d1ed220f0300b30ab6a3 (patch)
tree73c5cf53dcedb63a0e90d5741f7dc805bf5374ac /src/thread/pthread_kill.c
parentbae862ab18186aba5cd80f1443492f7730dff5f3 (diff)
downloadmusl-be82e122bf37fdcd1766d1ed220f0300b30ab6a3.tar.gz
musl-be82e122bf37fdcd1766d1ed220f0300b30ab6a3.tar.xz
musl-be82e122bf37fdcd1766d1ed220f0300b30ab6a3.zip
if returning errno value directly from a syscall, we need to negate it.
Diffstat (limited to 'src/thread/pthread_kill.c')
-rw-r--r--src/thread/pthread_kill.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/thread/pthread_kill.c b/src/thread/pthread_kill.c
index 6448d978..17aa5c4b 100644
--- a/src/thread/pthread_kill.c
+++ b/src/thread/pthread_kill.c
@@ -2,5 +2,5 @@
 
 int pthread_kill(pthread_t t, int sig)
 {
-	return __syscall(__NR_tgkill, t->pid, t->tid, sig);
+	return -__syscall(__NR_tgkill, t->pid, t->tid, sig);
 }