Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

in prelist_update(), made sure to keep the current stored lifetime

when not updating.
  • Loading branch information...
commit c7b2e10cad79e3e272312db863d9b9ad65e03226 1 parent 6fa0ea2
jinmei authored
Showing with 5 additions and 2 deletions.
  1. +5 −2 kame/sys/netinet6/nd6_rtr.c
View
7 kame/sys/netinet6/nd6_rtr.c
@@ -1,4 +1,4 @@
-/* $KAME: nd6_rtr.c,v 1.227 2003/02/07 15:09:28 suz Exp $ */
+/* $KAME: nd6_rtr.c,v 1.228 2003/03/22 09:03:15 jinmei Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -1506,6 +1506,10 @@ prelist_update(new, dr, m)
} else
storedlifetime = lt6_tmp.ia6t_vltime -
(time_second - ifa6->ia6_updatetime);
+
+ /* when not updating, keep the current stored lifetime. */
+ lt6_tmp.ia6t_vltime = storedlifetime;
+
if (TWOHOUR < new->ndpr_vltime ||
storedlifetime < new->ndpr_vltime) {
lt6_tmp.ia6t_vltime = new->ndpr_vltime;
@@ -2323,7 +2327,6 @@ in6_init_address_ltimes(struct nd_prefix *new, struct in6_addrlifetime *lt6)
long time_second = time.tv_sec;
#endif
- /* Valid lifetime must not be updated unless explicitly specified. */
/* init ia6t_expire */
if (lt6->ia6t_vltime == ND6_INFINITE_LIFETIME)
lt6->ia6t_expire = 0;
Please sign in to comment.
Something went wrong with that request. Please try again.