Commit aa67bec9 authored by Jehan's avatar Jehan

Bug 704510 - GIMP segfaults on OSX.

setenv() does not behave well on some systems, in particular OSX (and
probably some BSDs), when the set value is NULL. In this case, let's
unsetenv() the environment variable instead.
parent d682135d
......@@ -211,7 +211,10 @@ gimp_language_store_self_l10n (GimpLanguageStore *store,
g_setenv ("LANGUAGE", temp_lang, TRUE);
setlocale (LC_ALL, "");
lang = dgettext ("iso_639", lang);
g_setenv ("LANGUAGE", current_lang, TRUE);
if (current_lang)
g_setenv ("LANGUAGE", current_lang, TRUE);
else
g_unsetenv("LANGUAGE");
setlocale (LC_ALL, "");
g_free (current_lang);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment