From: Patrick McHardy <kaber@trash.net>
To: davem@davemloft.net
Cc: netfilter-devel@lists.netfilter.org, Patrick McHardy <kaber@trash.net>
Subject: [NETFILTER 01/06]: x_tables: fix xt_register_table error propagation
Date: Mon, 26 Jun 2006 17:43:08 +0200 (MEST) [thread overview]
Message-ID: <20060626154308.11682.91317.sendpatchset@localhost.localdomain> (raw)
In-Reply-To: <20060626154307.11682.28562.sendpatchset@localhost.localdomain>
[NETFILTER]: x_tables: fix xt_register_table error propagation
When xt_register_table fails the error is not properly propagated back.
Based on patch by Lepton Wu <ytht.net@gmail.com>.
Signed-off-by: Patrick McHardy <kaber@trash.net>
---
commit c223657397019f91ab8f7a7b8b417eae4a378c72
tree 016c6c6cd56cd11ef4d4250ab083da1894df03eb
parent 80cd9e86e65901f97f3c77b914985cff387d331d
author Patrick McHardy <kaber@trash.net> Mon, 19 Jun 2006 16:48:07 +0200
committer Patrick McHardy <kaber@trash.net> Mon, 19 Jun 2006 16:48:07 +0200
net/ipv4/netfilter/arp_tables.c | 3 ++-
net/ipv4/netfilter/ip_tables.c | 3 ++-
net/ipv6/netfilter/ip6_tables.c | 3 ++-
3 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/net/ipv4/netfilter/arp_tables.c b/net/ipv4/netfilter/arp_tables.c
index d0d1919..ad39bf6 100644
--- a/net/ipv4/netfilter/arp_tables.c
+++ b/net/ipv4/netfilter/arp_tables.c
@@ -1120,7 +1120,8 @@ int arpt_register_table(struct arpt_tabl
return ret;
}
- if (xt_register_table(table, &bootstrap, newinfo) != 0) {
+ ret = xt_register_table(table, &bootstrap, newinfo);
+ if (ret != 0) {
xt_free_table_info(newinfo);
return ret;
}
diff --git a/net/ipv4/netfilter/ip_tables.c b/net/ipv4/netfilter/ip_tables.c
index cee3397..101ad98 100644
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
@@ -2113,7 +2113,8 @@ int ipt_register_table(struct xt_table *
return ret;
}
- if (xt_register_table(table, &bootstrap, newinfo) != 0) {
+ ret = xt_register_table(table, &bootstrap, newinfo);
+ if (ret != 0) {
xt_free_table_info(newinfo);
return ret;
}
diff --git a/net/ipv6/netfilter/ip6_tables.c b/net/ipv6/netfilter/ip6_tables.c
index 2e72f89..0b5bd55 100644
--- a/net/ipv6/netfilter/ip6_tables.c
+++ b/net/ipv6/netfilter/ip6_tables.c
@@ -1281,7 +1281,8 @@ int ip6t_register_table(struct xt_table
return ret;
}
- if (xt_register_table(table, &bootstrap, newinfo) != 0) {
+ ret = xt_register_table(table, &bootstrap, newinfo);
+ if (ret != 0) {
xt_free_table_info(newinfo);
return ret;
}
next prev parent reply other threads:[~2006-06-26 15:43 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-06-26 15:43 [NETFILTER 00/06]: Netfilter Update Patrick McHardy
2006-06-26 15:43 ` Patrick McHardy [this message]
2006-06-26 15:43 ` [NETFILTER 02/06]: nf_conntrack: Fix undefined references to local_bh_* Patrick McHardy
2006-06-26 15:43 ` [NETFILTER 03/06]: xt_tcpudp: fix double unregistration in error path Patrick McHardy
2006-06-26 15:43 ` [NETFILTER 04/06]: xt_sctp: fix --chunk-types matching Patrick McHardy
2006-06-26 15:43 ` [NETFILTER 05/06]: ip_queue/nfnetlink_queue: drop bridge port references when dev disappears Patrick McHardy
2006-06-26 15:43 ` [NETFILTER 06/06]: statistic match: add missing Kconfig help text Patrick McHardy
2006-06-27 10:02 ` [NETFILTER 00/06]: Netfilter Update 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=20060626154308.11682.91317.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.