aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2010-10-29 00:50:09 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2010-10-29 00:50:09 +0200
commit6b3f0b0dab46d910f7797dfc8d8554546dd33fa2 (patch)
tree7399fa18cf6eb03941dbd999579673fa8e4c0ad4
parentdc8ef353fd8ae0641a53c2507138155dcd5f76e7 (diff)
downloadbusybox-w32-6b3f0b0dab46d910f7797dfc8d8554546dd33fa2.tar.gz
busybox-w32-6b3f0b0dab46d910f7797dfc8d8554546dd33fa2.tar.bz2
busybox-w32-6b3f0b0dab46d910f7797dfc8d8554546dd33fa2.zip
unicode: update unicode_width on !unicode branch too. Closes bug 2593
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--libbb/unicode.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libbb/unicode.c b/libbb/unicode.c
index 70c6abe00..cf0c6bed9 100644
--- a/libbb/unicode.c
+++ b/libbb/unicode.c
@@ -1005,8 +1005,11 @@ static char* FAST_FUNC unicode_conv_to_printable2(uni_stat_t *stats, const char
1005 d++; 1005 d++;
1006 } 1006 }
1007 } 1007 }
1008 if (stats) 1008 if (stats) {
1009 stats->byte_count = stats->unicode_count = (d - dst); 1009 stats->byte_count = (d - dst);
1010 stats->unicode_count = (d - dst);
1011 stats->unicode_width = (d - dst);
1012 }
1010 return dst; 1013 return dst;
1011 } 1014 }
1012 1015