summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2017-09-01 11:51:42 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2017-09-01 12:03:02 +0200
commit02844570df1717c073d8364a2999119e613d7488 (patch)
tree9f508e7cd61a6887c36d56e5505e0b27b6f96842 /include
parentc12759edf7c20cb923b8e3f359413bc9e59b8e11 (diff)
src: move nf_sock into nft_ctx structure
The idea is to provide a simplistic API for non-netlink wise people. Add a field in struct nft_ctx to store the socket. The advanced API that we're planning will just simply leave this unset, since netlink IO will be exposed. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include')
-rw-r--r--include/nftables.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/nftables.h b/include/nftables.h
index 256b06ee..5035567a 100644
--- a/include/nftables.h
+++ b/include/nftables.h
@@ -38,7 +38,10 @@ struct nft_cache {
uint32_t seqnum;
};
+struct mnl_socket;
+
struct nft_ctx {
+ struct mnl_socket *nf_sock;
const char *include_paths[INCLUDE_PATHS_MAX];
unsigned int num_include_paths;
unsigned int parser_max_errors;