diff options
author | Rosen Penev <rosenp@gmail.com> | 2020-03-26 16:07:12 -0700 |
---|---|---|
committer | Hans Dedecker <dedeckeh@gmail.com> | 2020-03-28 09:19:37 +0100 |
commit | fbf14aee4ad321ac3702b60ff8193d82812c2270 (patch) | |
tree | 660a0268d89f1fc436d3a6ab0a54864752e134db /src/odhcpd.c | |
parent | 6594c6b182a9065570316cf3a7a6a72a7afda150 (diff) |
odhcpd: fix compilation with musl 1.2.0
SYS_clock_gettime is gone with musl 1.2.0. Switched to the function.
Also fixed two format strings that fail as time_t is 64-bit with 1.2.0.
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Diffstat (limited to 'src/odhcpd.c')
-rw-r--r-- | src/odhcpd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/odhcpd.c b/src/odhcpd.c index 4b8e589..26094b1 100644 --- a/src/odhcpd.c +++ b/src/odhcpd.c @@ -440,7 +440,7 @@ int odhcpd_urandom(void *data, size_t len) time_t odhcpd_time(void) { struct timespec ts; - syscall(SYS_clock_gettime, CLOCK_MONOTONIC, &ts); + clock_gettime(CLOCK_MONOTONIC, &ts); return ts.tv_sec; } |