From d0ca3022a4041e7232587b024ebfaadbe2c095cc Mon Sep 17 00:00:00 2001 From: Steven Barth Date: Tue, 14 Jul 2015 21:49:57 +0200 Subject: [PATCH] router: fix invalid router lifetime --- src/router.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/router.c b/src/router.c index fada62b..51fd954 100644 --- a/src/router.c +++ b/src/router.c @@ -437,7 +437,7 @@ static uint64_t send_router_advert(struct interface *iface, const struct in6_add minival = (maxival * 3) / 4; if (adv.h.nd_ra_router_lifetime) - adv.h.nd_ra_router_lifetime = htons(maxvalid); + adv.h.nd_ra_router_lifetime = htons(maxvalid / 1000); odhcpd_urandom(&msecs, sizeof(msecs)); msecs = (labs(msecs) % (maxival - minival)) + minival; -- 2.25.1