Use computed string length.
authorLaurent Monin <geeqie@norz.org>
Sun, 11 May 2008 11:44:58 +0000 (11:44 +0000)
committerLaurent Monin <geeqie@norz.org>
Sun, 11 May 2008 11:44:58 +0000 (11:44 +0000)
src/ui_help.c

index 29d7d0b..8a33f39 100644 (file)
@@ -125,7 +125,7 @@ static void help_window_load_text(GtkWidget *text, const gchar *path)
 
                        if (!g_utf8_validate(s_buf, l, NULL))
                                {
-                               buf = g_locale_to_utf8(s_buf, strlen(s_buf), NULL, NULL, NULL);
+                               buf = g_locale_to_utf8(s_buf, l, NULL, NULL, NULL);
                                if (!buf) buf = g_strdup("\n");
                                }
                        else