On 17 February 2011 13:37, Anthony Liguori<address@hidden> wrote:
An application has to explicitly support an encoding. It is not
transparent. UCS2/UTF-16 means that strings are not 'const char *'s but
'const wchar_t *' where typedef unsigned short wchar_t;.
QEMU assumes, in lots of places that strings are single-byte NUL terminated.
Basically, any use of snprintf, printf, strcpy, strlen, etc. pretty much
tie you to ASCII/UTF-8.
Er, no, it limits you to those encodings where you can treat strings
as "bag of NUL-terminated bytes". Oddly enough just about all the
common legacy ones (iso-8859-*, iso-2022-jp, etc) fit in that category
because otherwise they'd break really badly.