From 7a6f12d75034fed940ce635e76a13123430f088e Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Sat, 27 Oct 2018 12:02:02 +0200 Subject: src: add nft_ctx_output_{get,set}_json() to nft_ctx_output_{get,set}_flags Add NFT_CTX_OUTPUT_JSON flag and display output in json format. Acked-by: Phil Sutter Signed-off-by: Pablo Neira Ayuso --- include/nftables/libnftables.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'include/nftables/libnftables.h') diff --git a/include/nftables/libnftables.h b/include/nftables/libnftables.h index a6ce9383..35374072 100644 --- a/include/nftables/libnftables.h +++ b/include/nftables/libnftables.h @@ -49,6 +49,7 @@ enum { NFT_CTX_OUTPUT_SERVICE = (1 << 1), NFT_CTX_OUTPUT_STATELESS = (1 << 2), NFT_CTX_OUTPUT_HANDLE = (1 << 3), + NFT_CTX_OUTPUT_JSON = (1 << 4), }; unsigned int nft_ctx_output_get_flags(struct nft_ctx *ctx); @@ -60,8 +61,6 @@ unsigned int nft_ctx_output_get_debug(struct nft_ctx *ctx); void nft_ctx_output_set_debug(struct nft_ctx *ctx, unsigned int mask); bool nft_ctx_output_get_echo(struct nft_ctx *ctx); void nft_ctx_output_set_echo(struct nft_ctx *ctx, bool val); -bool nft_ctx_output_get_json(struct nft_ctx *ctx); -void nft_ctx_output_set_json(struct nft_ctx *ctx, bool val); FILE *nft_ctx_set_output(struct nft_ctx *ctx, FILE *fp); int nft_ctx_buffer_output(struct nft_ctx *ctx); -- cgit v1.2.3