Commit d632ffe1 authored by Rémi Duraffort's avatar Rémi Duraffort

Prefer setenv to putenv (evenmore with local variables).

parent 10fcb9f9
......@@ -1212,10 +1212,7 @@ static void SetLanguage ( const char *psz_lang )
* the language at runtime under eg. Windows. Beware that this
* makes the environment unconsistent when libvlc is unloaded and
* should probably be moved to a safer place like vlc.c. */
static char psz_lcall[20];
snprintf( psz_lcall, 19, "LC_ALL=%s", psz_lang );
psz_lcall[19] = '\0';
putenv( psz_lcall );
setenv( "LC_ALL", psz_lang, 1 );
#endif
setlocale( LC_ALL, psz_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