From 66964cf6bf6fc6069b6d94e4a1adf973cc07443b Mon Sep 17 00:00:00 2001 From: Donatas Abraitis Date: Wed, 12 Jan 2022 22:50:26 +0200 Subject: [PATCH] bgpd: Use vty_json() for bgp_print_dampening_parameters() Signed-off-by: Donatas Abraitis --- bgpd/bgp_damp.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/bgpd/bgp_damp.c b/bgpd/bgp_damp.c index 90b7958c43..91e983e5d5 100644 --- a/bgpd/bgp_damp.c +++ b/bgpd/bgp_damp.c @@ -672,10 +672,7 @@ static int bgp_print_dampening_parameters(struct bgp *bgp, struct vty *vty, json_object_int_add(json, "maxSuppressPenalty", bdc->ceiling); - vty_out(vty, "%s\n", - json_object_to_json_string_ext( - json, JSON_C_TO_STRING_PRETTY)); - json_object_free(json); + vty_json(vty, json); } else { vty_out(vty, "Half-life time: %lld min\n", (long long)bdc->half_life / 60);