summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: aef462c)
raw | patch | inline | side by side (parent: aef462c)
author | Max Kellermann <max@duempel.org> | |
Fri, 3 Oct 2008 09:52:13 +0000 (11:52 +0200) | ||
committer | Max Kellermann <max@duempel.org> | |
Fri, 3 Oct 2008 09:52:13 +0000 (11:52 +0200) |
The GTK charset functions accept "-1" if the parameter is null
terminated.
terminated.
src/charset.c | patch | blob | history |
diff --git a/src/charset.c b/src/charset.c
index 095817d1502a5b2ed761cc7e036d22fc0f63502c..ccfac0ef86a454c339c2b7479c4eb801e1648fbf 100644 (file)
--- a/src/charset.c
+++ b/src/charset.c
if (noconvert)
return g_strdup(utf8str);
- str = g_convert_with_fallback(utf8str, strlen(utf8str),
+ str = g_convert_with_fallback(utf8str, -1,
charset, "utf-8",
NULL, NULL, NULL,
&error);
if (noconvert)
return g_strdup(localestr);
- str = g_convert_with_fallback(localestr, strlen(localestr),
+ str = g_convert_with_fallback(localestr, -1,
"utf-8", charset,
NULL, NULL, NULL,
&error);