diff options
author | James Zern <jzern@google.com> | 2016-07-01 14:34:09 -0700 |
---|---|---|
committer | James Zern <jzern@google.com> | 2016-07-01 19:36:58 -0700 |
commit | 7954e67bb85b6b13ab8ff4036fff29bfc3547901 (patch) | |
tree | d9c5339bc45b83a756cd1f9eac44c0d9314e79ed /vpx_util | |
parent | a48d42a804a267b57b7c9a6390450731caedeea2 (diff) | |
download | libvpx-7954e67bb85b6b13ab8ff4036fff29bfc3547901.tar libvpx-7954e67bb85b6b13ab8ff4036fff29bfc3547901.tar.gz libvpx-7954e67bb85b6b13ab8ff4036fff29bfc3547901.tar.bz2 libvpx-7954e67bb85b6b13ab8ff4036fff29bfc3547901.zip |
vpx_thread: use WaitForSingleObjectEx if available
BUG=b/29583578
original webp change:
commit 0fd0e12bfe83f16ce4f1c038b251ccbc13c62ac2
Author: James Zern <jzern@google.com>
Date: Mon Nov 23 20:40:26 2015 -0800
thread: use WaitForSingleObjectEx if available
Windows XP and up
Change-Id: Ie1a46a82722b8624437c8aba0aa4566a4b0b3f57
100644 blob d58f74e5523dbc985fc531cf5f0833f1e9157cf0 src/utils/thread.c
100644 blob 840831185502d42a3246e4b7ff870121c8064791 src/utils/thread.h
Change-Id: If165c38b378c6e0c55e17a1b071efd3ec3e7dcdd
Diffstat (limited to 'vpx_util')
-rw-r--r-- | vpx_util/vpx_thread.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/vpx_util/vpx_thread.h b/vpx_util/vpx_thread.h index cf55a75e7..30f47a14d 100644 --- a/vpx_util/vpx_thread.h +++ b/vpx_util/vpx_thread.h @@ -52,6 +52,11 @@ typedef struct { #define THREADFN unsigned int __stdcall #define THREAD_RETURN(val) (unsigned int)((DWORD_PTR)val) +#if _WIN32_WINNT >= 0x0501 // Windows XP or greater +#define WaitForSingleObject(obj, timeout) \ + WaitForSingleObjectEx(obj, timeout, FALSE /*bAlertable*/) +#endif + static INLINE int pthread_create(pthread_t* const thread, const void* attr, unsigned int (__stdcall *start)(void*), void* arg) { |