Commit c435b2e5 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Win32 vlc.exe: simplify by not calling asprintf

Suggestion from funman
parent 95690e16
......@@ -164,11 +164,9 @@ int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance,
if (lang && strncmp( lang, "auto", 4 ) )
{
char *tmp;
if (asprintf(&tmp, "LANG=%s", lang) != -1 ) {
putenv(tmp);
free(tmp);
}
char tmp[11];
snprintf(tmp, 11, "LANG=%s", lang);
putenv(tmp);
}
free(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