From f6d6449c88812634e663cef4e09db7b691af3eb5 Mon Sep 17 00:00:00 2001 From: Rob Leslie Date: Tue, 28 Sep 2010 00:43:00 -0700 Subject: iptables-restore: resolve confusing policy error message When iptables-restore (and ip6tables-restore) is unable to set a chain's policy, it responds with a confusing message, e.g.: iptables-restore v1.4.9: Can't set policy "PREROUTING" on "ACCEPT" line 16: Bad built-in chain name This is due to the chain and policy arguments being used in the wrong order. The attached patch corrects this problem. Signed-off-by: Jan Engelhardt --- ip6tables-restore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ip6tables-restore.c') diff --git a/ip6tables-restore.c b/ip6tables-restore.c index 008566c4..cea5f36e 100644 --- a/ip6tables-restore.c +++ b/ip6tables-restore.c @@ -312,7 +312,7 @@ int main(int argc, char *argv[]) xtables_error(OTHER_PROBLEM, "Can't set policy `%s'" " on `%s' line %u: %s\n", - chain, policy, line, + policy, chain, line, ip6tc_strerror(errno)); } -- cgit v1.2.3