diff options
Diffstat (limited to 'libbb')
| -rw-r--r-- | libbb/lineedit.c | 2 | ||||
| -rw-r--r-- | libbb/printable_string.c | 7 | ||||
| -rw-r--r-- | libbb/unicode.c | 2 |
3 files changed, 8 insertions, 3 deletions
diff --git a/libbb/lineedit.c b/libbb/lineedit.c index d5e92e84c..b1e971f88 100644 --- a/libbb/lineedit.c +++ b/libbb/lineedit.c | |||
| @@ -1086,7 +1086,7 @@ static void showfiles(void) | |||
| 1086 | ); | 1086 | ); |
| 1087 | } | 1087 | } |
| 1088 | if (ENABLE_UNICODE_SUPPORT) | 1088 | if (ENABLE_UNICODE_SUPPORT) |
| 1089 | puts(printable_string(NULL, matches[n])); | 1089 | puts(printable_string(matches[n])); |
| 1090 | else | 1090 | else |
| 1091 | puts(matches[n]); | 1091 | puts(matches[n]); |
| 1092 | } | 1092 | } |
diff --git a/libbb/printable_string.c b/libbb/printable_string.c index 077d58d32..a814fd03c 100644 --- a/libbb/printable_string.c +++ b/libbb/printable_string.c | |||
| @@ -9,7 +9,7 @@ | |||
| 9 | #include "libbb.h" | 9 | #include "libbb.h" |
| 10 | #include "unicode.h" | 10 | #include "unicode.h" |
| 11 | 11 | ||
| 12 | const char* FAST_FUNC printable_string(uni_stat_t *stats, const char *str) | 12 | const char* FAST_FUNC printable_string2(uni_stat_t *stats, const char *str) |
| 13 | { | 13 | { |
| 14 | char *dst; | 14 | char *dst; |
| 15 | const char *s; | 15 | const char *s; |
| @@ -55,3 +55,8 @@ const char* FAST_FUNC printable_string(uni_stat_t *stats, const char *str) | |||
| 55 | #endif | 55 | #endif |
| 56 | return auto_string(dst); | 56 | return auto_string(dst); |
| 57 | } | 57 | } |
| 58 | |||
| 59 | const char* FAST_FUNC printable_string(const char *str) | ||
| 60 | { | ||
| 61 | return printable_string2(NULL, str); | ||
| 62 | } | ||
diff --git a/libbb/unicode.c b/libbb/unicode.c index d378175a4..89d42179b 100644 --- a/libbb/unicode.c +++ b/libbb/unicode.c | |||
| @@ -996,7 +996,7 @@ size_t FAST_FUNC unicode_strlen(const char *string) | |||
| 996 | size_t FAST_FUNC unicode_strwidth(const char *string) | 996 | size_t FAST_FUNC unicode_strwidth(const char *string) |
| 997 | { | 997 | { |
| 998 | uni_stat_t uni_stat; | 998 | uni_stat_t uni_stat; |
| 999 | printable_string(&uni_stat, string); | 999 | printable_string2(&uni_stat, string); |
| 1000 | return uni_stat.unicode_width; | 1000 | return uni_stat.unicode_width; |
| 1001 | } | 1001 | } |
| 1002 | 1002 | ||
