| Index: runtime/bin/thread_fuchsia.cc
|
| diff --git a/runtime/bin/thread_fuchsia.cc b/runtime/bin/thread_fuchsia.cc
|
| index 5a9b35103af78bad7c7cc95655928cbb3e2418bb..5b458d29d4af8dc2dc20ecee9ccc9c5f8875040c 100644
|
| --- a/runtime/bin/thread_fuchsia.cc
|
| +++ b/runtime/bin/thread_fuchsia.cc
|
| @@ -290,7 +290,12 @@ Monitor::WaitResult Monitor::WaitMicros(int64_t micros) {
|
| Monitor::WaitResult retval = kNotified;
|
| if (micros == kNoTimeout) {
|
| // Wait forever.
|
| - int result = pthread_cond_wait(data_.cond(), data_.mutex());
|
| + int result;
|
| + do {
|
| + result = pthread_cond_wait(data_.cond(), data_.mutex());
|
| + // TODO(MG-795): Disallow ETIMEDOUT when pthread_cond_wait() can no longer
|
| + // return it.
|
| + } while (result == ETIMEDOUT);
|
| VALIDATE_PTHREAD_RESULT(result);
|
| } else {
|
| struct timespec ts;
|
|
|