From: Phil Sutter Date: Fri, 8 Jun 2018 15:27:15 +0000 (+0200) Subject: JSON: Don't print burst if equal to 5 X-Git-Tag: v0.9.1~393 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=cd102c36aedf2a8f65ff235a009f297352cd6b65;p=thirdparty%2Fnftables.git JSON: Don't print burst if equal to 5 Analogous to commit 3dddef928d80d ("statement: don't print burst if equals 5"), don't print the default burst value. Signed-off-by: Phil Sutter Signed-off-by: Pablo Neira Ayuso --- diff --git a/src/json.c b/src/json.c index 306cab7b..9019982a 100644 --- a/src/json.c +++ b/src/json.c @@ -990,7 +990,7 @@ json_t *limit_stmt_json(const struct stmt *stmt, struct output_ctx *octx) json_object_set_new(root, "inv", json_boolean(inv)); if (rate_unit) json_object_set_new(root, "rate_unit", json_string(rate_unit)); - if (burst) { + if (burst && burst != 5) { json_object_set_new(root, "burst", json_integer(burst)); if (burst_unit) json_object_set_new(root, "burst_unit",