diff --git a/src/thread/sem_timedwait.c b/src/thread/sem_timedwait.c index 8132eb1bf7a276d9b2dd2c9c978bbc0f0b29b7f4..58d3ebfefc8896258a29620cb750de947aa7e5aa 100644 --- a/src/thread/sem_timedwait.c +++ b/src/thread/sem_timedwait.c @@ -22,7 +22,7 @@ int sem_timedwait(sem_t *restrict sem, const struct timespec *restrict at) pthread_cleanup_push(cleanup, (void *)(sem->__val+1)); r = __timedwait_cp(sem->__val, -1, CLOCK_REALTIME, at, sem->__val[2]); pthread_cleanup_pop(1); - if (r && r != EINTR) { + if (r) { errno = r; return -1; }