===== net/ipv6/addrconf.c 1.115 vs edited ===== --- 1.115/net/ipv6/addrconf.c 2004-10-26 14:11:35 +10:00 +++ edited/net/ipv6/addrconf.c 2004-11-06 15:37:54 +11:00 @@ -484,7 +484,7 @@ int scope, unsigned flags) { struct inet6_ifaddr *ifa = NULL; - struct rt6_info *rt; + struct rt6_info *rt = NULL; int hash; static spinlock_t lock = SPIN_LOCK_UNLOCKED; int err = 0; @@ -572,6 +572,10 @@ if (unlikely(err == 0)) notifier_call_chain(&inet6addr_chain, NETDEV_UP, ifa); else { + if (rt) { + dst_release(&rt->u.dst); + dst_free(&rt->u.dst); + } kfree(ifa); ifa = ERR_PTR(err); }