summaryrefslogtreecommitdiff
path: root/src/internal
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2014-08-22 23:49:54 -0400
committerRich Felker <dalias@aerifal.cx>2014-08-22 23:49:54 -0400
commitb8ca9eb5301580dcf101753451eee196edceefbd (patch)
tree9602bfb40fbb328360bd024d2e416824cea63337 /src/internal
parenta6293285e930dbdb0eff47e29b513ca22537b1a2 (diff)
downloadmusl-b8ca9eb5301580dcf101753451eee196edceefbd.tar.gz
fix fallback checks for kernels without private futex support
for unknown syscall commands, the kernel produces ENOSYS, not EINVAL.
Diffstat (limited to 'src/internal')
-rw-r--r--src/internal/pthread_impl.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/internal/pthread_impl.h b/src/internal/pthread_impl.h
index 2d090f8f..4de66378 100644
--- a/src/internal/pthread_impl.h
+++ b/src/internal/pthread_impl.h
@@ -112,7 +112,7 @@ static inline void __wake(volatile void *addr, int cnt, int priv)
{
if (priv) priv = 128;
if (cnt<0) cnt = INT_MAX;
- __syscall(SYS_futex, addr, FUTEX_WAKE|priv, cnt) != -EINVAL ||
+ __syscall(SYS_futex, addr, FUTEX_WAKE|priv, cnt) != -ENOSYS ||
__syscall(SYS_futex, addr, FUTEX_WAKE, cnt);
}