diff options
-rw-r--r-- | src/odhcp6c.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/odhcp6c.c b/src/odhcp6c.c index 19a86f2..dbe15ff 100644 --- a/src/odhcp6c.c +++ b/src/odhcp6c.c @@ -639,8 +639,9 @@ static int usage(void) // Don't want to pull-in librt and libpthread just for a monotonic clock... uint64_t odhcp6c_get_milli_time(void) { - struct timespec t = {0, 0}; - syscall(SYS_clock_gettime, CLOCK_MONOTONIC, &t); + struct timespec t; + + clock_gettime(CLOCK_MONOTONIC, &t); return ((uint64_t)t.tv_sec) * 1000 + ((uint64_t)t.tv_nsec) / 1000000; } |