From 77c921df53c74e1682d9802c19ad030a70079cc6 Mon Sep 17 00:00:00 2001 From: Ivana Hutarova Varekova Date: Fri, 27 Sep 2013 07:10:21 +0200 Subject: [PATCH] cgexec: polish usage function This change is suggested by Dhaval Giani . Polish "usage" function of cgexec tool. Remove a level of indentation. Signed-off-by: Ivana Hutarova Varekova Acked-by: Dhaval Giani Acked-by: Jan Safranek --- src/tools/cgexec.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/src/tools/cgexec.c b/src/tools/cgexec.c index 30725b3f..a6b8e4f6 100644 --- a/src/tools/cgexec.c +++ b/src/tools/cgexec.c @@ -42,20 +42,19 @@ static struct option longopts[] = { static void usage(int status, const char *program_name) { - if (status != 0) + if (status != 0) { fprintf(stderr, "Wrong input parameters," " try %s --help' for more information.\n", program_name); - else { - printf("Usage: %s [-h] [-g :] " - "[--sticky] command [arguments] ...\n", - program_name); - printf("Run the task in given control groups\n"); - printf(" -g : Control "\ - "group which should be added\n"); - printf(" --sticky cgred "\ - "daemon does not change pidlist and children tasks\n"); + return; } + printf("Usage: %s [-h] [-g :] [--sticky] "\ + "command [arguments] ...\n", program_name); + printf("Run the task in given control group(s)\n"); + printf(" -g : Control group which "\ + "should be added\n"); + printf(" --sticky cgred daemon does not "\ + "change pidlist and children tasks\n"); } -- 2.47.2