diff --git a/core/src/syscall/unix/pthread_cond_timedwait.rs b/core/src/syscall/unix/pthread_cond_timedwait.rs index f060737b..7ad6e407 100644 --- a/core/src/syscall/unix/pthread_cond_timedwait.rs +++ b/core/src/syscall/unix/pthread_cond_timedwait.rs @@ -60,6 +60,15 @@ impl PthreadCondTimedwaitSyscall lock: *mut pthread_mutex_t, abstime: *const timespec, ) -> c_int { + #[cfg(all(unix, feature = "preemptive"))] + if crate::monitor::Monitor::current().is_some() { + return self.inner.pthread_cond_timedwait( + fn_ptr, + cond, + lock, + abstime, + ); + } let abstimeout = if abstime.is_null() { u64::MAX } else {