[vlc-devel] [PATCH 1/2] lua: add a guess_encoding function to convert Latin1 to UTF8
Edward Wang
edward.c.wang at compdigitec.com
Tue Aug 27 19:14:38 CEST 2013
On Tue, Aug 27, 2013 at 7:09 PM, Rémi Denis-Courmont <remi at remlab.net> wrote:
> I really do not think that one call to a function that detects UTF-8 and falls
> back to Latin-1
IsUTF8 ( psz_input ) ? strdup ( psz_input ) : FromLatin1 ( psz_input );
If input string is UTF8
-> return said string [implies string is UTF8 by IF statement]
else [implies string is NOT UTF8]
-> return said string converted to UTF8
IsUTF8 ( psz_input ) ?
I don't see where the "falling back" is?
Regards,
Edward Wang
More information about the vlc-devel
mailing list