diff options
author | Elliott Hughes <enh@google.com> | 2016-04-25 23:22:31 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2016-04-25 23:22:31 +0000 |
commit | 32e2d0f76893f1b6bde0caa19247df8262776e2b (patch) | |
tree | fbd0ebd769a40e2157c50eaed7b0017c7c2c8fb9 | |
parent | 33dcaf9b52649785bff0c56b48f84a8218354888 (diff) | |
parent | 0c50a3f6ae463c24c5c85de64b4bbcd77269d43e (diff) | |
download | native-32e2d0f76893f1b6bde0caa19247df8262776e2b.tar.gz |
Merge "Remove HAVE_PTHREAD_COND_TIMEDWAIT_RELATIVE test."
-rw-r--r-- | libs/binder/tests/binderLibTest.cpp | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/libs/binder/tests/binderLibTest.cpp b/libs/binder/tests/binderLibTest.cpp index 3df3acf9db..17479ca77e 100644 --- a/libs/binder/tests/binderLibTest.cpp +++ b/libs/binder/tests/binderLibTest.cpp @@ -252,14 +252,10 @@ class BinderLibTestEvent int ret; pthread_mutex_lock(&m_waitMutex); if (!m_eventTriggered) { -#if defined(HAVE_PTHREAD_COND_TIMEDWAIT_RELATIVE) - pthread_cond_timeout_np(&m_waitCond, &m_waitMutex, timeout_s * 1000); -#else struct timespec ts; clock_gettime(CLOCK_REALTIME, &ts); ts.tv_sec += timeout_s; pthread_cond_timedwait(&m_waitCond, &m_waitMutex, &ts); -#endif } ret = m_eventTriggered ? NO_ERROR : TIMED_OUT; pthread_mutex_unlock(&m_waitMutex); @@ -739,14 +735,10 @@ class BinderLibTestService : public BBinder } if (ret > 0) { if (m_serverStartRequested) { -#if defined(HAVE_PTHREAD_COND_TIMEDWAIT_RELATIVE) - ret = pthread_cond_timeout_np(&m_serverWaitCond, &m_serverWaitMutex, 5000); -#else struct timespec ts; clock_gettime(CLOCK_REALTIME, &ts); ts.tv_sec += 5; ret = pthread_cond_timedwait(&m_serverWaitCond, &m_serverWaitMutex, &ts); -#endif } if (m_serverStartRequested) { m_serverStartRequested = false; |