Correct padding for strings with multi-byte chars

This is a trivial bug fix for a situation when string arguments that contained characters that were encoded in multiple bytes got wrong padding. It happened because the length in chars instead of length in bytes was used to calculate the number of padding bytes.