On 10/05/2011 03:12 PM, Martin Gracik wrote:
What about this? gchar *normalizeLang(const gchar *s) { if (g_str_has_suffix(s, ".utf8")) { gchar *lang = g_strndup(s, strlen(s) - strlen(".utf8")); gchar *result = g_strconcat(lang, ".UTF-8", NULL); g_free(lang); return result; } return g_strdup(s); } Not sure if I don't have any leaks there...
Thanks, this is much better, I should start using glib more. I'll post a new patch soon. Ales _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list