Skip to content
Snippets Groups Projects
Commit 8f919a6c authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

More fixups for clock selection.

parent 5a5bd4a1
Branches
Tags
No related merge requests found
Pipeline #7776 failed
......@@ -1145,11 +1145,13 @@ int64_t xp_fast_timer64(void)
if (clock_getres(CLOCK_MONOTONIC_RAW, &ts) == 0)
cid = CLOCK_MONOTONIC_RAW;
}
cid = CLOCK_MONOTONIC_RAW;
#endif
#ifdef CLOCK_MONOTONIC
if (cid == CLOCK_REALTIME)
if (cid == CLOCK_REALTIME) {
cid = CLOCK_MONOTONIC;
if (clock_getres(CLOCK_MONOTONIC, &ts) == 0)
cid = CLOCK_MONOTONIC;
}
#endif
if (clock_gettime(cid, &ts) == 0)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment