Skip to contentSkip to conversation

clusterip: exit_net cleanup check added

PATCH Superseded Vasily Averin 1 participant 1 message Nov 5, 2017

Subsystems (3)

v1 of 5 Superseded Latest is v5 →

lore
Share & tools
lore
#0 lore raw

PATCH 9/21 clusterip: exit_net cleanup check added

Be sure that configs list initialized in net_init hook was return to initial state.

---
 net/ipv4/netfilter/ipt_CLUSTERIP.c | 2 ++
 1 file changed, 2 insertions(+)
net/ipv4/netfilter/ipt_CLUSTERIP.c +2 -0
index 17b4ca5..aa6ada3 100644
@@ -819,6 +819,8 @@ static void clusterip_net_exit(struct net *net)
 	cn->procdir = NULL;
 #endif
 	nf_unregister_net_hook(net, &cip_arp_ops);
+	WARN(!list_empty(&cn->configs),
+	     "net %p exit: clusterip configs list is not empty\n", net);
 }
 
 static struct pernet_operations clusterip_net_ops = {
Signature · 1 line
2.7.4