From 10a6bde56813620846826fed6979b2548a6457ea Mon Sep 17 00:00:00 2001 From: Pierre d'Herbemont Date: Thu, 31 Jul 2008 22:57:50 +0200 Subject: [PATCH] libvlccore: Don't set the priority on first thread on Mac OS X. Let's don't by pass the defaults here. This also fixes an thread error at exit. --- src/libvlc.c | 6 ------ src/misc/threads.c | 5 ----- 2 files changed, 11 deletions(-) diff --git a/src/libvlc.c b/src/libvlc.c index 411ce92e9b..842aa7270b 100644 --- a/src/libvlc.c +++ b/src/libvlc.c @@ -306,12 +306,6 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc, 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 ) { diff --git a/src/misc/threads.c b/src/misc/threads.c index 2405bdb372..266584e17e 100644 --- a/src/misc/threads.c +++ b/src/misc/threads.c @@ -624,13 +624,8 @@ int __vlc_thread_set_priority( vlc_object_t *p_this, const char * psz_file, if( !p_priv->b_thread ) { -#ifndef __APPLE__ msg_Err( p_this, "couldn't set priority of non-existent thread" ); return ESRCH; -#else -# warning FIXME: this is wrong - p_priv->b_thread = pthread_self(); -#endif } #if defined( LIBVLC_USE_PTHREAD ) -- 2.39.2