Chromium Code Reviews| Index: runtime/vm/os_fuchsia.cc |
| diff --git a/runtime/vm/os_fuchsia.cc b/runtime/vm/os_fuchsia.cc |
| index 209c825e5f1056a4e2892de27fe6060c99a9e9f1..7ae0eb73bda9eb1a21a7dbcfd2f48d588b82548c 100644 |
| --- a/runtime/vm/os_fuchsia.cc |
| +++ b/runtime/vm/os_fuchsia.cc |
| @@ -162,13 +162,13 @@ uintptr_t OS::MaxRSS() { |
| void OS::Sleep(int64_t millis) { |
|
zra
2017/04/17 20:03:26
This should probably just call SleepMicros.
|
| - mx_nanosleep(millis * kMicrosecondsPerMillisecond * |
| - kNanosecondsPerMicrosecond); |
| + mx_nanosleep(mx_deadline_after( |
| + millis * kMicrosecondsPerMillisecond * kNanosecondsPerMicrosecond)); |
| } |
| void OS::SleepMicros(int64_t micros) { |
| - mx_nanosleep(micros * kNanosecondsPerMicrosecond); |
| + mx_nanosleep(mx_deadline_after(micros * kNanosecondsPerMicrosecond)); |
| } |