diff options
author | Glenn L McGrath | 2002-11-28 08:33:04 +0000 |
---|---|---|
committer | Glenn L McGrath | 2002-11-28 08:33:04 +0000 |
commit | 6ead3abd5549b9342245820fbac6dd32647bdcb1 (patch) | |
tree | cf850ce4472b929e008395d161bdd1380d275ec7 | |
parent | 9c802416ab981c947a5bdd27663e34c11ea679d4 (diff) | |
download | busybox-6ead3abd5549b9342245820fbac6dd32647bdcb1.zip busybox-6ead3abd5549b9342245820fbac6dd32647bdcb1.tar.gz |
Save a few bytes in show_usage
-rw-r--r-- | applets/applets.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/applets/applets.c b/applets/applets.c index 1685018..e214f85 100644 --- a/applets/applets.c +++ b/applets/applets.c @@ -80,7 +80,6 @@ static struct BB_suid_config *suid_config; extern void show_usage(void) { - const char *format_string; const char *usage_string = usage_messages; int i; @@ -89,11 +88,12 @@ extern void show_usage(void) --i; } } - format_string = "%s\n\nUsage: %s %s\n\n"; - if(*usage_string == '\b') - format_string = "%s\n\nNo help available.\n\n"; - fprintf(stderr, format_string, - full_version, applet_using->name, usage_string); + + if(*usage_string == '\b') { + fprintf(stderr, "%s\n\nNo help available.\n\n", full_version); + } else { + fprintf(stderr, "%s\n\nUsage: %s %s\n\n", full_version, applet_using->name, usage_string); + } exit(EXIT_FAILURE); } |