return VLC_EGENERIC;
}
-#ifdef __APPLE__
- /* vlc_thread_set_priority needs to query the config,
- * so this is the earliest moment where we can set this */
- vlc_thread_set_priority( p_libvlc, VLC_THREAD_PRIORITY_LOW );
-#endif
-
/* Check for short help option */
if( config_GetInt( p_libvlc, "help" ) > 0 )
{
* 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 );
static const char psz_path[] = LOCALEDIR;
#else
char psz_path[1024];
- if (snprintf (psz_path, sizeof (psz_path), "%s/%s",
- vlc_global()->psz_vlcpath, "locale")
+ if (snprintf (psz_path, sizeof (psz_path), "%s" DIR_SEP "%s",
+ config_GetDataDir(), "locale")
>= (int)sizeof (psz_path))
return -1;