summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonatas Abraitis <donatas.abraitis@gmail.com>2022-01-12 22:50:26 +0200
committerDonatas Abraitis <donatas.abraitis@gmail.com>2022-01-12 22:50:26 +0200
commit66964cf6bf6fc6069b6d94e4a1adf973cc07443b (patch)
tree0312c13c3ce67806eb3b61cce3fb4dc4b1b8e336
parent4be03f305b39eca9f126658d4aa64b84e3755f63 (diff)
bgpd: Use vty_json() for bgp_print_dampening_parameters()
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
-rw-r--r--bgpd/bgp_damp.c5
1 files changed, 1 insertions, 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);