# HG changeset patch # User Sean Egan # Date 1060664576 0 # Node ID 650e9b73ba388f6a607ff98bffd6a0f7577ce606 # Parent b3744996da0d408f9e1d67ac0d885257a7862676 [gaim-migrate @ 6947] "Even if the conversion was successful, this may be less than len if there were partial characters at the end of the input." committer: Tailor Script diff -r b3744996da0d -r 650e9b73ba38 src/util.c --- a/src/util.c Tue Aug 12 01:39:36 2003 +0000 +++ b/src/util.c Tue Aug 12 05:02:56 2003 +0000 @@ -869,12 +869,11 @@ } utf8 = g_locale_to_utf8(str, -1, &converted, NULL, NULL); - if (utf8 && converted == strlen (str)) { + if (utf8) return(utf8); - } else if (utf8) { - g_free(utf8); - } - + + g_free(utf8); + utf8 = g_convert(str, -1, "UTF-8", "ISO-8859-15", &converted, NULL, NULL); if (utf8 && converted == strlen (str)) { return(utf8);