Commit d94a5a02 authored by ivoire's avatar ivoire
Browse files

Revert "Prefer setenv to putenv (evenmore with local variables)."

This commit build compilation on window.

This reverts commit d632ffe1.
parent 5ad6561c
......@@ -1206,7 +1206,10 @@ 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. */
setenv( "LC_ALL", psz_lang, 1 );
static char psz_lcall[20];
snprintf( psz_lcall, 19, "LC_ALL=%s", psz_lang );
psz_lcall[19] = '\0';
putenv( psz_lcall );
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