Replace CLOCK_MONOTONIC with SYSTEM_TIME_MONOTONIC

Using SYSTEM_TIME_MONOTONIC works for Android (where it translates to
CLOCK_MONOTONIC) and host targets, while CLOCK_MONOTONIC is not defined
on macOS.

Bug: 117921091
Test: existing tests should pass
Change-Id: I1fad472881830fb0701a320cf37319e083932ad4
This commit is contained in:
Jerome Gaillard
2019-06-14 12:58:57 +01:00
parent f06c22660f
commit e218c69285
12 changed files with 21 additions and 27 deletions

View File

@@ -69,7 +69,7 @@ int DrawFrameTask::drawFrame() {
LOG_ALWAYS_FATAL_IF(!mContext, "Cannot drawFrame with no CanvasContext!");
mSyncResult = SyncResult::OK;
mSyncQueued = systemTime(CLOCK_MONOTONIC);
mSyncQueued = systemTime(SYSTEM_TIME_MONOTONIC);
postAndWait();
return mSyncResult;