From 09f0d47b213de944303a320a70bf57e143bfed62 Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Fri, 4 May 2018 11:25:00 +0200 Subject: iptables-compat: do not fail on restore if user chain exists The following snippet fails if user chain FOO exists, but it should not fail: iptables-compat -F iptables-compat -N FOO iptables-compat-save > foo iptables-compat-restore < foo Reported-by: Florian Westphal Signed-off-by: Pablo Neira Ayuso --- iptables/nft-shared.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'iptables/nft-shared.h') diff --git a/iptables/nft-shared.h b/iptables/nft-shared.h index 525f3f0e..089828a3 100644 --- a/iptables/nft-shared.h +++ b/iptables/nft-shared.h @@ -256,7 +256,7 @@ struct nft_xt_restore_cb { int (*chain_user_add)(struct nft_handle *h, const char *chain, const char *table); - int (*rule_flush)(struct nft_handle *h, const char *chain, const char *table); + int (*table_flush)(struct nft_handle *h, const char *table); int (*do_command)(struct nft_handle *h, int argc, char *argv[], char **table, bool restore); -- cgit v1.2.3