]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - net/netfilter/nfnetlink_queue.c
[IPV4]: Add ICMPMsgStats MIB (RFC 4293)
[karo-tx-linux.git] / net / netfilter / nfnetlink_queue.c
index bb65a38c816c79d88561feaacaa6734df57a6a5e..c97369f48db7844482cd15eaa648e297166139a7 100644 (file)
@@ -734,6 +734,9 @@ nfqnl_rcv_dev_event(struct notifier_block *this,
 {
        struct net_device *dev = ptr;
 
+       if (dev->nd_net != &init_net)
+               return NOTIFY_DONE;
+
        /* Drop any packets associated with the downed device */
        if (event == NETDEV_DOWN)
                nfqnl_dev_drop(dev->ifindex);
@@ -762,7 +765,8 @@ nfqnl_rcv_nl_event(struct notifier_block *this,
                        struct hlist_head *head = &instance_table[i];
 
                        hlist_for_each_entry_safe(inst, tmp, t2, head, hlist) {
-                               if (n->pid == inst->peer_pid)
+                               if ((n->net == &init_net) &&
+                                   (n->pid == inst->peer_pid))
                                        __instance_destroy(inst);
                        }
                }