aboutsummaryrefslogtreecommitdiff
path: root/coreutils/chmod.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2021-09-17 01:13:58 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2021-09-17 01:18:31 +0200
commit59ac467dc6429a48522ef7fbe40fcd819563e49a (patch)
tree4b6af971b0ffc516294ff35ba7b5c1e99c6eadae /coreutils/chmod.c
parent4958c18134eb7ad169cdaf22a9ad957ad4f4858c (diff)
downloadbusybox-w32-59ac467dc6429a48522ef7fbe40fcd819563e49a.tar.gz
busybox-w32-59ac467dc6429a48522ef7fbe40fcd819563e49a.tar.bz2
busybox-w32-59ac467dc6429a48522ef7fbe40fcd819563e49a.zip
libbb: eliminate a static data array in bb_mode_string()
function old new delta print_stat 861 869 +8 header_verbose_list_ar 73 77 +4 display_single 975 979 +4 header_verbose_list 237 239 +2 bb_mode_string 124 115 -9 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 4/1 up/down: 18/-9) Total: 9 bytes text data bss dec hex filename 1043136 559 5052 1048747 1000ab busybox_old 1043153 559 5020 1048732 10009c busybox_unstripped Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'coreutils/chmod.c')
-rw-r--r--coreutils/chmod.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/coreutils/chmod.c b/coreutils/chmod.c
index 8e3e1387e..5832cc51b 100644
--- a/coreutils/chmod.c
+++ b/coreutils/chmod.c
@@ -91,8 +91,9 @@ static int FAST_FUNC fileAction(struct recursive_state *state,
91 || (OPT_CHANGED 91 || (OPT_CHANGED
92 && (statbuf->st_mode & 07777) != (newmode & 07777)) 92 && (statbuf->st_mode & 07777) != (newmode & 07777))
93 ) { 93 ) {
94 char modestr[12];
94 printf("mode of '%s' changed to %04o (%s)\n", fileName, 95 printf("mode of '%s' changed to %04o (%s)\n", fileName,
95 newmode & 07777, bb_mode_string(newmode)+1); 96 newmode & 07777, bb_mode_string(modestr, newmode)+1);
96 } 97 }
97 return TRUE; 98 return TRUE;
98 } 99 }