path: root/iptables/nft.h
diff options
authorPhil Sutter <>2019-07-22 12:16:22 +0200
committerPablo Neira Ayuso <>2019-07-23 21:14:40 +0200
commit80e1d5cba738d0b9b7f5ffab8e5e7d02d6b06eeb (patch)
treeef240fd4db6a7c93aa92453eda2bf6e84a2381bb /iptables/nft.h
parent9449b90ec24cd71c4fe4212ed4970074e54dfa8a (diff)
nft: Make nft_for_each_table() more versatile
Support passing arbitrary data (via void pointer) to the callback. Signed-off-by: Phil Sutter <> Signed-off-by: Pablo Neira Ayuso <>
Diffstat (limited to 'iptables/nft.h')
1 files changed, 1 insertions, 1 deletions
diff --git a/iptables/nft.h b/iptables/nft.h
index dc116184..da078a44 100644
--- a/iptables/nft.h
+++ b/iptables/nft.h
@@ -81,7 +81,7 @@ void nft_build_cache(struct nft_handle *h);
struct nftnl_table;
struct nftnl_chain_list;
-int nft_for_each_table(struct nft_handle *h, int (*func)(struct nft_handle *h, const char *tablename, bool counters), bool counters);
+int nft_for_each_table(struct nft_handle *h, int (*func)(struct nft_handle *h, const char *tablename, void *data), void *data);
bool nft_table_find(struct nft_handle *h, const char *tablename);
int nft_table_purge_chains(struct nft_handle *h, const char *table, struct nftnl_chain_list *list);
int nft_table_flush(struct nft_handle *h, const char *table);