1 diff -u -r ../util-linux-2.28/lib/monotonic.c ./lib/monotonic.c
2 --- ../util-linux-2.28/lib/monotonic.c 2016-02-19 05:30:53.576131474 -0500
3 +++ ./lib/monotonic.c 2016-06-23 06:09:05.035726383 -0400
5 if (gettimeofday(&now, NULL) != 0)
9 +#define TIMESPEC_TO_TIMEVAL(tv, ts) { \
10 + (tv)->tv_sec = (ts)->tv_sec; \
11 + (tv)->tv_usec = (ts)->tv_nsec / 1000; \
14 if (clock_gettime(CLOCK_BOOTTIME, &hires_uptime) == 0) {
15 TIMESPEC_TO_TIMEVAL(&lores_uptime, &hires_uptime);
16 timersub(&now, &lores_uptime, boot_time);