aboutsummaryrefslogtreecommitdiff
path: root/coreutils/ls.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2018-09-30 16:56:56 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2018-09-30 16:56:56 +0200
commit349d72c19ced4fae64e8fdd5792b37e78ac2f616 (patch)
treec7f228ac570984a552242e64fe815d212876c0dc /coreutils/ls.c
parent14454b3071c7a5c053fde8eed416ab3b2f8475fb (diff)
downloadbusybox-w32-349d72c19ced4fae64e8fdd5792b37e78ac2f616.tar.gz
busybox-w32-349d72c19ced4fae64e8fdd5792b37e78ac2f616.tar.bz2
busybox-w32-349d72c19ced4fae64e8fdd5792b37e78ac2f616.zip
unzip: use printable_string() for printing filenames
function old new delta unzip_main 2726 2792 +66 printable_string2 - 57 +57 identify 4329 4336 +7 expmeta 659 663 +4 add_interface 99 103 +4 beep_main 286 289 +3 changepath 192 194 +2 builtin_type 115 117 +2 devmem_main 469 470 +1 input_tab 1076 1074 -2 create_J 1821 1819 -2 poplocalvars 314 311 -3 doCommands 2222 2214 -8 do_load 918 902 -16 printable_string 57 9 -48 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 8/6 up/down: 146/-79) Total: 67 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'coreutils/ls.c')
-rw-r--r--coreutils/ls.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/coreutils/ls.c b/coreutils/ls.c
index b1c306809..db3ddb944 100644
--- a/coreutils/ls.c
+++ b/coreutils/ls.c
@@ -421,7 +421,7 @@ static unsigned calc_name_len(const char *name)
421 uni_stat_t uni_stat; 421 uni_stat_t uni_stat;
422 422
423 // TODO: quote tab as \t, etc, if -Q 423 // TODO: quote tab as \t, etc, if -Q
424 name = printable_string(&uni_stat, name); 424 name = printable_string2(&uni_stat, name);
425 425
426 if (!(option_mask32 & OPT_Q)) { 426 if (!(option_mask32 & OPT_Q)) {
427 return uni_stat.unicode_width; 427 return uni_stat.unicode_width;
@@ -450,7 +450,7 @@ static unsigned print_name(const char *name)
450 uni_stat_t uni_stat; 450 uni_stat_t uni_stat;
451 451
452 // TODO: quote tab as \t, etc, if -Q 452 // TODO: quote tab as \t, etc, if -Q
453 name = printable_string(&uni_stat, name); 453 name = printable_string2(&uni_stat, name);
454 454
455 if (!(option_mask32 & OPT_Q)) { 455 if (!(option_mask32 & OPT_Q)) {
456 fputs(name, stdout); 456 fputs(name, stdout);