From: Patrick McHardy <kaber@trash.net>
To: davem@davemloft.net
Cc: netfilter-devel@lists.netfilter.org, Patrick McHardy <kaber@trash.net>
Subject: [NETFILTER 04/05]: nf_conntrack: add missing unlock in get_next_corpse()
Date: Mon, 30 Oct 2006 19:19:01 +0100 (MET) [thread overview]
Message-ID: <20061030181859.32038.61354.sendpatchset@localhost.localdomain> (raw)
In-Reply-To: <20061030181853.32038.97693.sendpatchset@localhost.localdomain>
[NETFILTER]: nf_conntrack: add missing unlock in get_next_corpse()
Add missing unlock in get_next_corpse() in nf_conntrack. It was missed
during the removal of listhelp.h . Also remove an unneeded use of
nf_ct_tuplehash_to_ctrack() in the same function.
Should be applied before 2.6.19 is released.
Signed-off-by: Martin Josefsson <gandalf@wlug.westbo.se>
Signed-off-by: Patrick McHardy <kaber@trash.net>
---
commit 4de9f9e71c273a4f53f82c5dd3e48f25cb3893f9
tree 7ec3e2872f3820ed76117ea463adab561d9645b9
parent 2e3d7fd325d9327881f17aec50619caaf1aeab00
author Martin Josefsson <gandalf@wlug.westbo.se> Mon, 30 Oct 2006 16:31:19 +0100
committer Patrick McHardy <kaber@trash.net> Mon, 30 Oct 2006 16:31:19 +0100
net/netfilter/nf_conntrack_core.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/net/netfilter/nf_conntrack_core.c b/net/netfilter/nf_conntrack_core.c
index 093b3dd..836541e 100644
--- a/net/netfilter/nf_conntrack_core.c
+++ b/net/netfilter/nf_conntrack_core.c
@@ -1520,9 +1520,10 @@ get_next_corpse(int (*iter)(struct nf_co
if (iter(ct, data))
goto found;
}
+ write_unlock_bh(&nf_conntrack_lock);
return NULL;
found:
- atomic_inc(&nf_ct_tuplehash_to_ctrack(h)->ct_general.use);
+ atomic_inc(&ct->ct_general.use);
write_unlock_bh(&nf_conntrack_lock);
return ct;
}
next prev parent reply other threads:[~2006-10-30 18:19 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-30 18:18 [NETFILTER 00/05]: Netfilter fixes Patrick McHardy
2006-10-30 18:18 ` [NETFILTER 01/05]: remove masq/NAT from ip6tables Kconfig help Patrick McHardy
2006-10-30 23:12 ` David Miller
2006-10-30 18:18 ` [NETFILTER 02/05]: Missed and reordered checks in {arp, ip, ip6}_tables Patrick McHardy
2006-10-30 23:13 ` [NETFILTER 02/05]: Missed and reordered checks in {arp,ip,ip6}_tables David Miller
2006-10-30 18:19 ` [NETFILTER 03/05]: ip_tables: compat error way cleanup Patrick McHardy
2006-10-30 23:13 ` David Miller
2006-10-30 18:19 ` Patrick McHardy [this message]
2006-10-30 23:14 ` [NETFILTER 04/05]: nf_conntrack: add missing unlock in get_next_corpse() David Miller
2006-10-30 18:19 ` [NETFILTER 05/05]: ip_tables: compat code module refcounting fix Patrick McHardy
2006-10-30 23:14 ` David Miller
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=20061030181859.32038.61354.sendpatchset@localhost.localdomain \
--to=kaber@trash.net \
--cc=davem@davemloft.net \
--cc=netfilter-devel@lists.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 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.