diff options
author | Denis V. Lunev <den@openvz.org> | 2008-01-28 17:41:19 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:08:07 -0500 |
commit | b7c6ba6eb1234e35a74fb8ba8123232a7b1ba9e4 (patch) | |
tree | 672c08c95229a6ac242ab12a5195dceddb0f3127 /net/decnet | |
parent | 4f84d82f7a623f8641af2574425c329431ff158f (diff) |
[NETNS]: Consolidate kernel netlink socket destruction.
Create a specific helper for netlink kernel socket disposal. This just
let the code look better and provides a ground for proper disposal
inside a namespace.
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/decnet')
-rw-r--r-- | net/decnet/netfilter/dn_rtmsg.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/decnet/netfilter/dn_rtmsg.c b/net/decnet/netfilter/dn_rtmsg.c index 96375f2e64ff..6d2bd3202048 100644 --- a/net/decnet/netfilter/dn_rtmsg.c +++ b/net/decnet/netfilter/dn_rtmsg.c | |||
@@ -137,7 +137,7 @@ static int __init dn_rtmsg_init(void) | |||
137 | 137 | ||
138 | rv = nf_register_hook(&dnrmg_ops); | 138 | rv = nf_register_hook(&dnrmg_ops); |
139 | if (rv) { | 139 | if (rv) { |
140 | sock_release(dnrmg->sk_socket); | 140 | netlink_kernel_release(dnrmg); |
141 | } | 141 | } |
142 | 142 | ||
143 | return rv; | 143 | return rv; |
@@ -146,7 +146,7 @@ static int __init dn_rtmsg_init(void) | |||
146 | static void __exit dn_rtmsg_fini(void) | 146 | static void __exit dn_rtmsg_fini(void) |
147 | { | 147 | { |
148 | nf_unregister_hook(&dnrmg_ops); | 148 | nf_unregister_hook(&dnrmg_ops); |
149 | sock_release(dnrmg->sk_socket); | 149 | netlink_kernel_release(dnrmg); |
150 | } | 150 | } |
151 | 151 | ||
152 | 152 | ||