From 1494cc26fe524f25d3984b20938b51ce681cb44d Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Wed, 26 Sep 2018 17:57:01 +0200 Subject: mnl: remove alloc_nftnl_chain() The netlink layer sits in between the mnl and the rule layers, remove it. We can remove alloc_nftnl_chain() and consolidate infrastructure in the src/mnl.c file. Signed-off-by: Pablo Neira Ayuso --- include/mnl.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'include/mnl.h') diff --git a/include/mnl.h b/include/mnl.h index 44dd90f9..96bf4b03 100644 --- a/include/mnl.h +++ b/include/mnl.h @@ -36,10 +36,12 @@ int mnl_nft_rule_batch_replace(struct nftnl_rule *nlr, struct nftnl_batch *batch struct nftnl_rule_list *mnl_nft_rule_dump(struct netlink_ctx *ctx, int family); -int mnl_nft_chain_batch_add(struct nftnl_chain *nlc, struct nftnl_batch *batch, - unsigned int flags, uint32_t seqnum); -int mnl_nft_chain_batch_del(struct nftnl_chain *nlc, struct nftnl_batch *batch, - unsigned int flags, uint32_t seqnum); +int mnl_nft_chain_add(struct netlink_ctx *ctx, const struct cmd *cmd, + unsigned int flags); +int mnl_nft_chain_del(struct netlink_ctx *ctx, const struct cmd *cmd); +int mnl_nft_chain_rename(struct netlink_ctx *ctx, const struct cmd *cmd, + const struct chain *chain); + struct nftnl_chain_list *mnl_nft_chain_dump(struct netlink_ctx *ctx, int family); -- cgit v1.2.3