From: Eric Dumazet <eric.dumazet@gmail.com>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: netdev <netdev@vger.kernel.org>,
netfilter-devel <netfilter-devel@vger.kernel.org>,
David Miller <davem@davemloft.net>
Subject: [PATCH net-next] netfilter: remove two dropwatch false positives
Date: Wed, 02 May 2012 09:13:10 +0200 [thread overview]
Message-ID: <1335942790.22133.55.camel@edumazet-glaptop> (raw)
From: Eric Dumazet <edumazet@google.com>
After skb_copy_expand() call, we want to switch skbs without dropping
original one. Call consume_skb() to avoid drop_monitor sending a drop
event.
Signed-off-by: Eric Dumazet <edumazet@google.com>
---
net/ipv4/netfilter/ip_queue.c | 2 +-
net/ipv6/netfilter/ip6_queue.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/ipv4/netfilter/ip_queue.c b/net/ipv4/netfilter/ip_queue.c
index 09775a1..dd88537 100644
--- a/net/ipv4/netfilter/ip_queue.c
+++ b/net/ipv4/netfilter/ip_queue.c
@@ -296,7 +296,7 @@ ipq_mangle_ipv4(ipq_verdict_msg_t *v, struct nf_queue_entry *e)
"in mangle, dropping packet\n");
return -ENOMEM;
}
- kfree_skb(e->skb);
+ consume_skb(e->skb);
e->skb = nskb;
}
skb_put(e->skb, diff);
diff --git a/net/ipv6/netfilter/ip6_queue.c b/net/ipv6/netfilter/ip6_queue.c
index 3ca9303..e1d5465 100644
--- a/net/ipv6/netfilter/ip6_queue.c
+++ b/net/ipv6/netfilter/ip6_queue.c
@@ -296,7 +296,7 @@ ipq_mangle_ipv6(ipq_verdict_msg_t *v, struct nf_queue_entry *e)
"in mangle, dropping packet\n");
return -ENOMEM;
}
- kfree_skb(e->skb);
+ consume_skb(e->skb);
e->skb = nskb;
}
skb_put(e->skb, diff);
next reply other threads:[~2012-05-02 7:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-02 7:13 Eric Dumazet [this message]
2012-05-09 11:36 ` [PATCH net-next] netfilter: remove two dropwatch false positives Pablo Neira Ayuso
2012-05-09 13:00 ` Eric Dumazet
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1335942790.22133.55.camel@edumazet-glaptop \
--to=eric.dumazet@gmail.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=netfilter-devel@vger.kernel.org \
--cc=pablo@netfilter.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox