From 80e1d5cba738d0b9b7f5ffab8e5e7d02d6b06eeb Mon Sep 17 00:00:00 2001 From: Phil Sutter Date: Mon, 22 Jul 2019 12:16:22 +0200 Subject: 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 --- iptables/nft.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'iptables/nft.h') 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); -- cgit v1.2.3