From e8fd8c6b9bf53e646b84ae28b123379752fbd3c2 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Thu, 29 Jun 2017 11:07:54 +0200 Subject: [PATCH] uuidparse: se JSON table name on -J Signed-off-by: Karel Zak --- misc-utils/uuidparse.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/misc-utils/uuidparse.c b/misc-utils/uuidparse.c index d9dba493a5..400775e009 100644 --- a/misc-utils/uuidparse.c +++ b/misc-utils/uuidparse.c @@ -258,7 +258,10 @@ static void print_output(struct control const *const ctrl, int argc, if (!tb) err(EXIT_FAILURE, _("failed to allocate output table")); - scols_table_enable_json(tb, ctrl->json); + if (ctrl->json) { + scols_table_enable_json(tb, 1); + scols_table_set_name(tb, "uuids"); + } scols_table_enable_noheadings(tb, ctrl->no_headings); scols_table_enable_raw(tb, ctrl->raw); -- 2.47.3