netfilter: nf_nat: better error handling of nf_ct_expect_related() in helpers
authorPablo Neira Ayuso <pablo@netfilter.org>
Wed, 22 Sep 2010 06:34:12 +0000 (08:34 +0200)
committerPatrick McHardy <kaber@trash.net>
Wed, 22 Sep 2010 06:34:12 +0000 (08:34 +0200)
commit5b92b61f3891517d18d0573ad2c939c81b59ecfe
tree4d61d64041d559e6478a53f865fb779df99cedc9
parent26c15cfd291f8b4ee40b4bbdf5e3772adfd704f5
netfilter: nf_nat: better error handling of nf_ct_expect_related() in helpers

This patch improves the situation in which the expectation table is
full for conntrack NAT helpers. Basically, we give up if we don't
find a place in the table instead of looping over nf_ct_expect_related()
with a different port (we should only do this if it returns -EBUSY, for
-EMFILE or -ESHUTDOWN I think that it's better to skip this).

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Patrick McHardy <kaber@trash.net>
net/ipv4/netfilter/nf_nat_amanda.c
net/ipv4/netfilter/nf_nat_ftp.c
net/ipv4/netfilter/nf_nat_h323.c
net/ipv4/netfilter/nf_nat_irc.c
net/ipv4/netfilter/nf_nat_sip.c