From 360d6277d674c6f92135c8b6bf274c48675ef168 Mon Sep 17 00:00:00 2001 From: Phillip Susi Date: Mon, 5 Dec 2011 19:24:39 -0500 Subject: [PATCH 130/134] parted: Allow undocumented commands Have command_print_summary print nothing if the command summary is NULL. This allows for a command to be registered, but not documented in the output of help. --- parted/command.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/parted/command.c b/parted/command.c index e8fa64e..bc70e8a 100644 --- a/parted/command.c +++ b/parted/command.c @@ -118,6 +118,8 @@ command_get_names (Command** list) void command_print_summary (Command* cmd) { + if (cmd->summary == NULL) + return; fputs (" ", stdout); str_list_print_wrap (cmd->summary, screen_width(), 2, 8, stdout); putchar ('\n'); -- 1.9.3