summaryrefslogtreecommitdiffstats
path: root/usr.sbin/arp/arp.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/arp/arp.c')
-rw-r--r--usr.sbin/arp/arp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/arp/arp.c b/usr.sbin/arp/arp.c
index 32bfd9a..26674de 100644
--- a/usr.sbin/arp/arp.c
+++ b/usr.sbin/arp/arp.c
@@ -319,9 +319,9 @@ set(int argc, char **argv)
doing_proxy = flags = proxy_only = expire_time = 0;
while (argc-- > 0) {
if (strncmp(argv[0], "temp", 4) == 0) {
- struct timeval tv;
- gettimeofday(&tv, 0);
- expire_time = tv.tv_sec + 20 * 60;
+ struct timespec tp;
+ clock_gettime(CLOCK_MONOTONIC, &tp);
+ expire_time = tp.tv_sec + 20 * 60;
} else if (strncmp(argv[0], "pub", 3) == 0) {
flags |= RTF_ANNOUNCE;
doing_proxy = 1;
OpenPOWER on IntegriCloud