Re: [f16-branch 2/2] Handle strange lang boot argument values.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux