summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Obser <florian@cvs.openbsd.org>2017-04-17 10:29:02 +0000
committerFlorian Obser <florian@cvs.openbsd.org>2017-04-17 10:29:02 +0000
commit0899987984fe25b805a749b8d8c1def21883f46e (patch)
treeb3dcbc79eb3cd27e442e07d6ba17c842b9778469
parentdb96032a00551a6891582092ad1ceced6d7a18a8 (diff)
We need to update the ia6_updatetime when changing the vltime/pltime
vio ioctl(2). Otherwise ifconfig shows the wrong times since vltime/pltime are calculated from this value on export. The handling of router advertisements does the right thing. OK bluhm
-rw-r--r--sys/netinet6/in6.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/netinet6/in6.c b/sys/netinet6/in6.c
index 5aaef3b515b..ff005676845 100644
--- a/sys/netinet6/in6.c
+++ b/sys/netinet6/in6.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: in6.c,v 1.201 2017/03/16 10:42:01 florian Exp $ */
+/* $OpenBSD: in6.c,v 1.202 2017/04/17 10:29:01 florian Exp $ */
/* $KAME: in6.c,v 1.372 2004/06/14 08:14:21 itojun Exp $ */
/*
@@ -665,6 +665,7 @@ in6_update_ifa(struct ifnet *ifp, struct in6_aliasreq *ifra,
* to see if the address is deprecated or invalidated, but initialize
* these members for applications.
*/
+ ia6->ia6_updatetime = time_uptime;
ia6->ia6_lifetime = ifra->ifra_lifetime;
if (ia6->ia6_lifetime.ia6t_vltime != ND6_INFINITE_LIFETIME) {
ia6->ia6_lifetime.ia6t_expire =