Fix UTF-16 decoding where wchar_t is not 16-bit