diff options
author | Denis V. Lunev <den@openvz.org> | 2008-01-19 10:54:15 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-29 02:08:06 +0300 |
commit | 4f84d82f7a623f8641af2574425c329431ff158f (patch) | |
tree | 639acc6831d8d99d4ca4c2a5ec3c78831b41c084 /net/ipv4 | |
parent | 869e58f87094b1e8a0df49232e4a5172678d46c9 (diff) | |
download | linux-4f84d82f7a623f8641af2574425c329431ff158f.tar.xz |
[NETNS]: Memory leak on network namespace stop.
Network namespace allocates 2 kernel netlink sockets, fibnl &
rtnl. These sockets should be disposed properly, i.e. by
sock_release. Plain sock_put is not enough.
Signed-off-by: Denis V. Lunev <den@openvz.org>
Tested-by: Alexey Dobriyan <adobriyan@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/fib_frontend.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/fib_frontend.c b/net/ipv4/fib_frontend.c index 8ddcd3f91a17..4e5216e9aacb 100644 --- a/net/ipv4/fib_frontend.c +++ b/net/ipv4/fib_frontend.c @@ -881,7 +881,7 @@ static void nl_fib_lookup_exit(struct net *net) * initial network namespace. So the socket will be safe to free. */ net->ipv4.fibnl->sk_net = get_net(&init_net); - sock_put(net->ipv4.fibnl); + sock_release(net->ipv4.fibnl->sk_socket); } static void fib_disable_ip(struct net_device *dev, int force) |