aboutsummaryrefslogtreecommitdiff
path: root/libbb/appletlib.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2009-08-30 19:57:49 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2009-08-30 19:57:49 +0200
commit630dde1cef920dd8ff99bda0f3fdebfb564e2260 (patch)
treee2bd0146af3c549e5f2b8e9d9883b7ad6cb3fd95 /libbb/appletlib.c
parent1249dbb2c77af8543e58a4bb217196e1b97aff9b (diff)
downloadbusybox-w32-630dde1cef920dd8ff99bda0f3fdebfb564e2260.tar.gz
busybox-w32-630dde1cef920dd8ff99bda0f3fdebfb564e2260.tar.bz2
busybox-w32-630dde1cef920dd8ff99bda0f3fdebfb564e2260.zip
code shrink in help text code
text data bss dec hex filename 823690 458 6956 831104 cae80 busybox_old 823673 458 6956 831087 cae6f busybox_unstripped Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'libbb/appletlib.c')
-rw-r--r--libbb/appletlib.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/libbb/appletlib.c b/libbb/appletlib.c
index 48a8bb6f3..814b8bcd2 100644
--- a/libbb/appletlib.c
+++ b/libbb/appletlib.c
@@ -116,7 +116,8 @@ void FAST_FUNC bb_show_usage(void)
116 full_write2_str(p); 116 full_write2_str(p);
117 full_write2_str("\n\n"); 117 full_write2_str("\n\n");
118 } 118 }
119 dealloc_usage_messages((char*)usage_string); 119 if (ENABLE_FEATURE_CLEAN_UP)
120 dealloc_usage_messages((char*)usage_string);
120#else 121#else
121 const char *p; 122 const char *p;
122 const char *usage_string = p = unpack_usage_messages(); 123 const char *usage_string = p = unpack_usage_messages();
@@ -129,7 +130,7 @@ void FAST_FUNC bb_show_usage(void)
129 ap--; 130 ap--;
130 } 131 }
131 full_write2_str(bb_banner); 132 full_write2_str(bb_banner);
132 full_write2_str(" multi-call binary\n"); 133 full_write2_str(" multi-call binary.\n");
133 if (*p == '\b') 134 if (*p == '\b')
134 full_write2_str("\nNo help available.\n\n"); 135 full_write2_str("\nNo help available.\n\n");
135 else { 136 else {
@@ -139,7 +140,8 @@ void FAST_FUNC bb_show_usage(void)
139 full_write2_str(p); 140 full_write2_str(p);
140 full_write2_str("\n\n"); 141 full_write2_str("\n\n");
141 } 142 }
142 dealloc_usage_messages((char*)usage_string); 143 if (ENABLE_FEATURE_CLEAN_UP)
144 dealloc_usage_messages((char*)usage_string);
143#endif 145#endif
144 } 146 }
145 xfunc_die(); 147 xfunc_die();
@@ -643,8 +645,9 @@ static int busybox_main(char **argv)
643 } 645 }
644 646
645 dup2(1, 2); 647 dup2(1, 2);
646 full_write2_str(bb_banner); /* reuse const string... */ 648 full_write2_str(bb_banner); /* reuse const string */
647 full_write2_str(" multi-call binary\n" 649 full_write2_str(" multi-call binary.\n"); /* reuse */
650 full_write2_str(
648 "Copyright (C) 1998-2009 Erik Andersen, Rob Landley, Denys Vlasenko\n" 651 "Copyright (C) 1998-2009 Erik Andersen, Rob Landley, Denys Vlasenko\n"
649 "and others. Licensed under GPLv2.\n" 652 "and others. Licensed under GPLv2.\n"
650 "See source distribution for full notice.\n" 653 "See source distribution for full notice.\n"
@@ -655,7 +658,7 @@ static int busybox_main(char **argv)
655 "\tBusyBox is a multi-call binary that combines many common Unix\n" 658 "\tBusyBox is a multi-call binary that combines many common Unix\n"
656 "\tutilities into a single executable. Most people will create a\n" 659 "\tutilities into a single executable. Most people will create a\n"
657 "\tlink to busybox for each function they wish to use and BusyBox\n" 660 "\tlink to busybox for each function they wish to use and BusyBox\n"
658 "\twill act like whatever it was invoked as!\n" 661 "\twill act like whatever it was invoked as.\n"
659 "\n" 662 "\n"
660 "Currently defined functions:\n"); 663 "Currently defined functions:\n");
661 col = 0; 664 col = 0;