From 7a3d637de41e44490d8af94675bb046fef443681 Mon Sep 17 00:00:00 2001 From: Jiri Bohac Date: Mon, 16 Apr 2012 03:34:39 +0000 Subject: [PATCH] --- yaml --- r: 299542 b: refs/heads/master c: edfb5d4687d587c9f714799c7ee27517118e12e6 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/include/net/ip6_fib.h | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index a639423c2e80..9c678c255807 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: b95465c8fcd7c8619ff9ff7bbf8038ab31c7f34b +refs/heads/master: edfb5d4687d587c9f714799c7ee27517118e12e6 diff --git a/trunk/include/net/ip6_fib.h b/trunk/include/net/ip6_fib.h index c64778fd5e13..cb8da1dac512 100644 --- a/trunk/include/net/ip6_fib.h +++ b/trunk/include/net/ip6_fib.h @@ -143,8 +143,14 @@ static inline void rt6_set_expires(struct rt6_info *rt, unsigned long expires) static inline void rt6_update_expires(struct rt6_info *rt, int timeout) { - if (!(rt->rt6i_flags & RTF_EXPIRES) && rt->dst.from) - dst_release(rt->dst.from); + if (!(rt->rt6i_flags & RTF_EXPIRES)) { + if (rt->dst.from) + dst_release(rt->dst.from); + /* dst_set_expires relies on expires == 0 + * if it has not been set previously. + */ + rt->dst.expires = 0; + } dst_set_expires(&rt->dst, timeout); rt->rt6i_flags |= RTF_EXPIRES;