summaryrefslogtreecommitdiff
path: root/mutex.c
diff options
context:
space:
mode:
authorrpj <rpj>2002-02-01 07:24:03 +0000
committerrpj <rpj>2002-02-01 07:24:03 +0000
commit6a65a568fa4d9515265842c8bcf11a7449f3c325 (patch)
tree35cd38d44cd0d61c7ba3a6026eb3e696e9173453 /mutex.c
parentf9c50f211c388410ccd8919f522cdd2c8d2d3904 (diff)
* semaphore.c (sem_trywait): Fix missing errno return
for systems that define NEED_SEM (e.g. early WinCE). * mutex.c (pthread_mutex_timedlock): Return ENOTSUP for systems that define NEED_SEM since they don't have sem_trywait().
Diffstat (limited to 'mutex.c')
-rw-r--r--mutex.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/mutex.c b/mutex.c
index 72847d5..85fdab4 100644
--- a/mutex.c
+++ b/mutex.c
@@ -835,6 +835,10 @@ pthread_mutex_timedlock(pthread_mutex_t *mutex, const struct timespec *abstime)
int result = 0;
pthread_mutex_t mx;
+#ifdef NEED_SEM
+ errno = ENOTSUP;
+ return -1;
+#endif
if (mutex == NULL || *mutex == NULL)
{