* [PATCH][Netfilter]: forgotten dev_put for bridge-devices in nf_reinject() in netfilter.c
@ 2002-12-15 22:40 Bart De Schuymer
2002-12-23 7:25 ` David S. Miller
0 siblings, 1 reply; 2+ messages in thread
From: Bart De Schuymer @ 2002-12-15 22:40 UTC (permalink / raw)
To: David S.Miller; +Cc: Netfilter Development Mailinglist
Hello David,
The following patch was sent last Tuesday (5 days ago) on the netdev and
netfilter-devel mailing lists and I don't see it in Linus' tree yet, so I
thought I'd send it directly to you.
The patch is from Patrick McHardy <kaber@trash.net>.
The problem was caused by the bridge-netfilter patch from me. nf_queue()
dev_holds the phys{in,out}dev devices, but nf_reinject() doesn't dev_put()
them.
If this is already in your patch queue, my apologies, otherwise,
please apply,
Bart
--- linux-2.5.50/net/core/netfilter.c.orig 2002-12-10 14:16:20.000000000 +0100
+++ linux-2.5.50/net/core/netfilter.c 2002-12-10 14:19:23.000000000 +0100
@@ -574,7 +574,15 @@
/* Release those devices we held, or Alexey will kill me. */
if (info->indev) dev_put(info->indev);
if (info->outdev) dev_put(info->outdev);
-
+#if defined(CONFIG_BRIDGE) || defined(CONFIG_BRIDGE_MODULE)
+ if (skb->nf_bridge) {
+ if (skb->nf_bridge->physindev)
+ dev_put(skb->nf_bridge->physindev);
+ if (skb->nf_bridge->physoutdev)
+ dev_put(skb->nf_bridge->physoutdev);
+ }
+#endif
+
kfree(info);
return;
}
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-12-23 7:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-12-15 22:40 [PATCH][Netfilter]: forgotten dev_put for bridge-devices in nf_reinject() in netfilter.c Bart De Schuymer
2002-12-23 7:25 ` David S. Miller
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.