Skip to content

Commit 279089f

Browse files
committed
Use clock_boottime_or_monotonic() everywhere to pick clocksrc.
This clocksrc is used every measurement and should be used everywhere, not just in one location.
1 parent 177ea92 commit 279089f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/store.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ static int skip = 0;
5353
double gettime_ns(void) {
5454
struct timespec n;
5555

56-
clock_gettime(CLOCK_MONOTONIC, &n);
56+
clock_gettime(clock_boottime_or_monotonic(), &n);
5757

5858
return (n.tv_sec + (n.tv_nsec / (double) NSEC_PER_SEC));
5959
}

0 commit comments

Comments
 (0)