Skip to content

Commit 669f8f1

Browse files
vaverindavem330
authored andcommitted
packet: exit_net cleanup check added
Be sure that packet.sklist initialized in net_init hook was return to initial state. Signed-off-by: Vasily Averin <vvs@virtuozzo.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent ab384b6 commit 669f8f1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

net/packet/af_packet.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4560,6 +4560,7 @@ static int __net_init packet_net_init(struct net *net)
45604560
static void __net_exit packet_net_exit(struct net *net)
45614561
{
45624562
remove_proc_entry("packet", net->proc_net);
4563+
WARN_ON_ONCE(!hlist_empty(&net->packet.sklist));
45634564
}
45644565

45654566
static struct pernet_operations packet_net_ops = {

0 commit comments

Comments
 (0)