summaryrefslogtreecommitdiffstats
path: root/iptables/nft.h
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2020-07-08 15:18:48 +0200
committerPhil Sutter <phil@nwl.cc>2020-07-24 19:16:09 +0200
commitdb3a63237fe21de8a75eaaddf0cc577ce30a68fe (patch)
tree95a3f9cce07890784feaf4b7a5892a860679f5f8 /iptables/nft.h
parent7a700c47fe121c65c550ab24de3284abbb1e82f8 (diff)
nft: Turn nft_chain_save() into a foreach-callback
Let nftnl_chain_list_foreach() do the chain list iterating instead of open-coding it. While being at it, simplify the policy value selection code as well. Signed-off-by: Phil Sutter <phil@nwl.cc>
Diffstat (limited to 'iptables/nft.h')
-rw-r--r--iptables/nft.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/iptables/nft.h b/iptables/nft.h
index bd944f44..fd390e7f 100644
--- a/iptables/nft.h
+++ b/iptables/nft.h
@@ -142,7 +142,7 @@ const struct builtin_table *nft_table_builtin_find(struct nft_handle *h, const c
struct nftnl_chain;
int nft_chain_set(struct nft_handle *h, const char *table, const char *chain, const char *policy, const struct xt_counters *counters);
-int nft_chain_save(struct nft_handle *h, struct nftnl_chain_list *list);
+int nft_chain_save(struct nftnl_chain *c, void *data);
int nft_chain_user_add(struct nft_handle *h, const char *chain, const char *table);
int nft_chain_user_del(struct nft_handle *h, const char *chain, const char *table, bool verbose);
int nft_chain_restore(struct nft_handle *h, const char *chain, const char *table);