Skip to content

Commit

Permalink
pppol2tp: calls unregister_pernet_gen_device() at unload time
Browse files Browse the repository at this point in the history
Failure to call unregister_pernet_gen_device() can exhaust memory
if module is loaded/unloaded many times.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Aug 2, 2009
1 parent a53a8b5 commit 446e72f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/net/pppol2tp.c
Original file line number Diff line number Diff line change
Expand Up @@ -2680,6 +2680,7 @@ static int __init pppol2tp_init(void)
static void __exit pppol2tp_exit(void)
{
unregister_pppox_proto(PX_PROTO_OL2TP);
unregister_pernet_gen_device(pppol2tp_net_id, &pppol2tp_net_ops);
proto_unregister(&pppol2tp_sk_proto);
}

Expand Down

0 comments on commit 446e72f

Please sign in to comment.