summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorTomasz Bursztyka <tomasz.bursztyka@linux.intel.com>2012-06-28 02:57:49 +0000
committerPablo Neira Ayuso <pablo@netfilter.org>2012-06-29 13:04:16 +0200
commit4009e18851ea555959c6017d848983b3d60bf667 (patch)
treee1d3b58b09f7ce3d5107347848bfc1aa02b9a6af /net
parentd31f4d448f7671dc3e6a7a1c92a4c085a36058bb (diff)
downloadlinux-4009e18851ea555959c6017d848983b3d60bf667.tar.bz2
netfilter: nfnetlink: fix missing rcu_read_unlock in nfnetlink_rcv_msg
Bug added in commit 6b75e3e8d664a9a (netfilter: nfnetlink: add RCU in nfnetlink_rcv_msg()) Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com> Acked-by: Eric Dumazet <edumazet@google.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net')
-rw-r--r--net/netfilter/nfnetlink.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/netfilter/nfnetlink.c b/net/netfilter/nfnetlink.c
index 3e797d1fcb94..791d56bbd74a 100644
--- a/net/netfilter/nfnetlink.c
+++ b/net/netfilter/nfnetlink.c
@@ -169,8 +169,10 @@ replay:
err = nla_parse(cda, ss->cb[cb_id].attr_count,
attr, attrlen, ss->cb[cb_id].policy);
- if (err < 0)
+ if (err < 0) {
+ rcu_read_unlock();
return err;
+ }
if (nc->call_rcu) {
err = nc->call_rcu(net->nfnl, skb, nlh,