]> err.no Git - linux-2.6/blobdiff - net/ipv6/ip6_fib.c
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland...
[linux-2.6] / net / ipv6 / ip6_fib.c
index b3f6e03c454cc7571800fc8b06538bdb5aa4c24e..1ee4fa17c12959a14c835663abdb81ce349f8de4 100644 (file)
@@ -772,6 +772,10 @@ out:
                 * If fib6_add_1 has cleared the old leaf pointer in the
                 * super-tree leaf node we have to find a new one for it.
                 */
+               if (pn != fn && pn->leaf == rt) {
+                       pn->leaf = NULL;
+                       atomic_dec(&rt->rt6i_ref);
+               }
                if (pn != fn && !pn->leaf && !(pn->fn_flags & RTN_RTINFO)) {
                        pn->leaf = fib6_find_prefix(info->nl_net, pn);
 #if RT6_DEBUG >= 2
@@ -1539,7 +1543,7 @@ out_timer:
 static void fib6_net_exit(struct net *net)
 {
        rt6_ifdown(net, NULL);
-       del_timer(net->ipv6.ip6_fib_timer);
+       del_timer_sync(net->ipv6.ip6_fib_timer);
        kfree(net->ipv6.ip6_fib_timer);
 #ifdef CONFIG_IPV6_MULTIPLE_TABLES
        kfree(net->ipv6.fib6_local_tbl);