summaryrefslogtreecommitdiffstats
path: root/include/nftables.h
diff options
context:
space:
mode:
authorVarsha Rao <rvarsha016@gmail.com>2017-08-13 10:00:18 +0530
committerPablo Neira Ayuso <pablo@netfilter.org>2017-08-14 11:32:21 +0200
commit07b45939972eb81c3c3db21c8589b51a62f4843a (patch)
treeb50dfd024653fd11f63821e2e7e4805dbb16036b /include/nftables.h
parentbb8e9e84a1b537ccf1b7abbc9d11af0383801a0d (diff)
src: introduce struct nft_cache
Pass variable cache_initialized and structure list_head as members of structure nft_cache. Joint work with Pablo Neira. Signed-off-by: Varsha Rao <rvarsha016@gmail.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include/nftables.h')
-rw-r--r--include/nftables.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/include/nftables.h b/include/nftables.h
index ca609015..a88c86d1 100644
--- a/include/nftables.h
+++ b/include/nftables.h
@@ -37,6 +37,11 @@ struct nft_ctx {
bool check;
};
+struct nft_cache {
+ bool initialized;
+ struct list_head list;
+};
+
extern unsigned int max_errors;
extern unsigned int debug_level;
extern const char *include_paths[INCLUDE_PATHS_MAX];
@@ -117,8 +122,9 @@ struct input_descriptor {
struct parser_state;
struct mnl_socket;
-int nft_run(struct nft_ctx *nft, struct mnl_socket *nf_sock, void *scanner,
- struct parser_state *state, struct list_head *msgs);
+int nft_run(struct nft_ctx *nft, struct mnl_socket *nf_sock,
+ struct nft_cache *cache, void *scanner, struct parser_state *state,
+ struct list_head *msgs);
void ct_label_table_init(void);
void mark_table_init(void);