diff options
Diffstat (limited to 'src/libtools/threads.c')
| -rwxr-xr-x | src/libtools/threads.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/libtools/threads.c b/src/libtools/threads.c index fb393a59..c62a1dcb 100755 --- a/src/libtools/threads.c +++ b/src/libtools/threads.c @@ -677,7 +677,12 @@ EXPORT int my_pthread_cond_wait(x64emu_t* emu, pthread_cond_t* cond, void* mutex EXPORT int my_pthread_cond_clockwait(x64emu_t *emu, pthread_cond_t* cond, void* mutex, __clockid_t __clock_id, const struct timespec* __abstime) { (void)emu; - return pthread_cond_clockwait(cond, getAlignedMutex((pthread_mutex_t*)mutex), __clock_id, __abstime); + if(real_pthread_cond_clockwait) + return real_pthread_cond_clockwait(cond, getAlignedMutex((pthread_mutex_t*)mutex), __clock_id, __abstime); + else { + errno = EINVAL; + return -1; + } } EXPORT void my__pthread_cleanup_push_defer(x64emu_t* emu, void* buffer, void* routine, void* arg) |