From: Álvaro Neira Ayuso <alvaroneay@xxxxxxxxx> Added missing curly braces in json output support Signed-off-by: Alvaro Neira Ayuso <alvaroneay@xxxxxxxxx> --- src/expr/bitwise.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/expr/bitwise.c b/src/expr/bitwise.c index f0a2eff..edc5a39 100644 --- a/src/expr/bitwise.c +++ b/src/expr/bitwise.c @@ -242,21 +242,21 @@ nft_rule_expr_bitwise_snprintf_json(char *buf, size_t size, bitwise->sreg, bitwise->dreg); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); - ret = snprintf(buf+offset, len, "\"mask\" : "); + ret = snprintf(buf+offset, len, "\"mask\" : {"); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); ret = nft_data_reg_snprintf(buf+offset, len, &bitwise->mask, NFT_RULE_O_JSON, 0, DATA_VALUE); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); - ret = snprintf(buf+offset, len, ", \"xor\" : "); + ret = snprintf(buf+offset, len, "}, \"xor\" : {"); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); ret = nft_data_reg_snprintf(buf+offset, len, &bitwise->xor, NFT_RULE_O_JSON, 0, DATA_VALUE); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); - ret = snprintf(buf+offset, len, "\""); + ret = snprintf(buf+offset, len, "}"); SNPRINTF_BUFFER_SIZE(ret, size, len, offset); return offset; -- To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html