diff options
author | David S. Miller <davem@davemloft.net> | 2012-06-09 19:12:36 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-06-09 19:12:36 -0700 |
commit | c0efc887dcadbdbfe171f028acfab9c7c00e9dde (patch) | |
tree | d2f628d6c222c6328a6f310378d7227c32ebf183 /net/ipv6 | |
parent | 8b51b064a6da90c68af5385a874968829a2a0ed7 (diff) |
inet: Pass inetpeer root into inet_getpeer*() interfaces.
Otherwise we reference potentially non-existing members when
ipv6 is disabled.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6')
-rw-r--r-- | net/ipv6/route.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/route.c b/net/ipv6/route.c index 9586c27e069c..8fc41d502bbd 100644 --- a/net/ipv6/route.c +++ b/net/ipv6/route.c @@ -306,7 +306,7 @@ void rt6_bind_peer(struct rt6_info *rt, int create) struct net *net = dev_net(rt->dst.dev); struct inet_peer *peer; - peer = inet_getpeer_v6(net, &rt->rt6i_dst.addr, create); + peer = inet_getpeer_v6(net->ipv6.peers, &rt->rt6i_dst.addr, create); if (peer && cmpxchg(&rt->rt6i_peer, NULL, peer) != NULL) inet_putpeer(peer); else |