]> git.puffer.fish Git - matthieu/frr.git/commitdiff
lib: Fix non-use of option
authorDonald Sharp <sharpd@nvidia.com>
Thu, 2 Feb 2023 21:28:27 +0000 (16:28 -0500)
committerDonatas Abraitis <donatas@opensourcerouting.org>
Thu, 16 Feb 2023 20:16:02 +0000 (22:16 +0200)
Commit d7c6467ba2f55d1055babbb7fe82716ca3efdc7e added the
ability to specify non pretty printing but unfortunately
forgot to use the option variable to make the whole
thing work.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
lib/vty.c

index 9d8966064aab61b8ae2d88d13fdd8d1f046ae871..169e78081dbce6ade84246e1bc65c2dbc4de9f30 100644 (file)
--- a/lib/vty.c
+++ b/lib/vty.c
@@ -290,7 +290,7 @@ static int vty_json_helper(struct vty *vty, struct json_object *json,
                return CMD_SUCCESS;
 
        text = json_object_to_json_string_ext(
-               json, JSON_C_TO_STRING_PRETTY | JSON_C_TO_STRING_NOSLASHESCAPE);
+               json, options);
        vty_out(vty, "%s\n", text);
        json_object_free(json);