Possible Unicode Problems in Busybox - Collect and Discussion

Harald Becker ralda at gmx.de
Wed Aug 13 19:05:34 UTC 2014


Hi Denys!

 >> 2) shell substitution ${#var}
>> Does this length operation shall give the number of bytes in var or the
>> number of characters (which may differ for multi byte characters, like
>> UTF-8).
>
> bash gives number of Unicode chars.
> I just fixed both ash and hush to do the same.

You fixed this one, but there are two more related shell substitutions 
to modify (sorry didn't find them earlier):

${xxx:offset}
${xxx:offset:length}

offset and length are given in number of characters in bash, BB ash uses 
bytes.





More information about the busybox mailing list