diff options
author | Elliott Hughes <enh@google.com> | 2017-01-27 15:55:28 -0800 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2017-01-28 17:41:16 -0600 |
commit | 70f7f10476311288049565573338a4a821cef8a5 (patch) | |
tree | 35c53bf0effb587ca67e3f21ab63ccb9c62797aa /toys/posix/ls.c | |
parent | 8ceb2dec8b7233385c1b2983c907592c46a48bd8 (diff) | |
download | toybox-70f7f10476311288049565573338a4a821cef8a5.tar.gz |
Add missing `static`s and remove an unused function.
Diffstat (limited to 'toys/posix/ls.c')
-rw-r--r-- | toys/posix/ls.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/toys/posix/ls.c b/toys/posix/ls.c index b306dc91..d2a2e466 100644 --- a/toys/posix/ls.c +++ b/toys/posix/ls.c @@ -65,7 +65,7 @@ GLOBALS( ) // Callback from crunch_str to represent unprintable chars -int crunch_qb(FILE *out, int cols, int wc) +static int crunch_qb(FILE *out, int cols, int wc) { unsigned len = 1; char buf[32]; @@ -98,16 +98,11 @@ int crunch_qb(FILE *out, int cols, int wc) } // Returns wcwidth(utf8) version of strlen with -qb escapes -int strwidth(char *s) +static int strwidth(char *s) { return crunch_str(&s, INT_MAX, 0, TT.escmore, crunch_qb); } -void qbstr(char *s, int width) -{ - draw_trim_esc(s, width, abs(width), TT.escmore, crunch_qb); -} - static char endtype(struct stat *st) { mode_t mode = st->st_mode; @@ -272,7 +267,7 @@ static unsigned long next_column(unsigned long ul, unsigned long dtlen, return (*xpos*height) + widecols + (ul/(columns-1)); } -int color_from_mode(mode_t mode) +static int color_from_mode(mode_t mode) { int color = 0; |