From 48636e1fe6f6d3141de735f9faf4c359938b837c Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Mon, 29 Oct 2018 12:11:09 +0100 Subject: src: add nft_ctx_output_{get,set}_echo() to nft_ctx_output_{get,set}_flags Add NFT_CTX_OUTPUT_ECHO flag and echo the command that has been send to the kernel. Acked-by: Phil Sutter Signed-off-by: Pablo Neira Ayuso --- src/parser_json.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/parser_json.c') diff --git a/src/parser_json.c b/src/parser_json.c index bc682e92..412f5cf2 100644 --- a/src/parser_json.c +++ b/src/parser_json.c @@ -3399,7 +3399,7 @@ int nft_parse_json_buffer(struct nft_ctx *nft, const char *buf, ret = __json_parse(&ctx); - if (!nft->output.echo) { + if (!nft_output_echo(&nft->output)) { json_decref(nft->json_root); nft->json_root = NULL; } @@ -3427,7 +3427,7 @@ int nft_parse_json_filename(struct nft_ctx *nft, const char *filename, ret = __json_parse(&ctx); - if (!nft->output.echo) { + if (!nft_output_echo(&nft->output)) { json_decref(nft->json_root); nft->json_root = NULL; } -- cgit v1.2.3