path: fix g_convert() argument order
g_convert() wants the destination character set first. This was mixed up.
This commit is contained in:
parent
1f50146e29
commit
ddab531b4a
@ -33,7 +33,7 @@ char *fs_charset_to_utf8(char *dst, const char *str)
|
|||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
|
|
||||||
p = g_convert(str, -1,
|
p = g_convert(str, -1,
|
||||||
fs_charset, "utf-8",
|
"utf-8", fs_charset,
|
||||||
NULL, NULL, &error);
|
NULL, NULL, &error);
|
||||||
if (p == NULL) {
|
if (p == NULL) {
|
||||||
/* no fallback */
|
/* no fallback */
|
||||||
@ -52,7 +52,7 @@ char *utf8_to_fs_charset(char *dst, const char *str)
|
|||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
|
|
||||||
p = g_convert(str, -1,
|
p = g_convert(str, -1,
|
||||||
"utf-8", fs_charset,
|
fs_charset, "utf-8",
|
||||||
NULL, NULL, &error);
|
NULL, NULL, &error);
|
||||||
if (p == NULL) {
|
if (p == NULL) {
|
||||||
/* fall back to UTF-8 */
|
/* fall back to UTF-8 */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user