X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fd91cec1417a06b5e0ee09b3e677da5cc73ea0a3..eecc043f6ccbe6cc9dbfe44aaff3e05382edac9b:/src/unix/threadpsx.cpp diff --git a/src/unix/threadpsx.cpp b/src/unix/threadpsx.cpp index a5fa470848..5d7c3bcd2a 100644 --- a/src/unix/threadpsx.cpp +++ b/src/unix/threadpsx.cpp @@ -255,6 +255,7 @@ wxMutexError wxMutexInternal::Lock() wxMutexError wxMutexInternal::Lock(unsigned long ms) { +#ifdef HAVE_PTHREAD_MUTEX_TIMEDLOCK static const long MSEC_IN_SEC = 1000; static const long NSEC_IN_MSEC = 1000000; static const long NSEC_IN_USEC = 1000; @@ -295,6 +296,11 @@ wxMutexError wxMutexInternal::Lock(unsigned long ms) } return HandleLockResult(pthread_mutex_timedlock(&m_mutex, &ts)); +#else // !HAVE_PTHREAD_MUTEX_TIMEDLOCK + wxUnusedVar(ms); + + return wxMUTEX_MISC_ERROR; +#endif // HAVE_PTHREAD_MUTEX_TIMEDLOCK/!HAVE_PTHREAD_MUTEX_TIMEDLOCK } wxMutexError wxMutexInternal::HandleLockResult(int err)