From 9c87bdf6b71f43aa5d2667d5cc9e483e9b6bddea Mon Sep 17 00:00:00 2001 From: =?utf8?q?R=C3=A9mi=20Denis-Courmont?= Date: Sun, 4 May 2008 19:34:34 +0300 Subject: [PATCH] Remove p_root->b_ready. Duplicated state. --- src/libvlc-common.c | 4 +--- src/libvlc.h | 2 -- src/misc/threads.c | 1 - 3 files changed, 1 insertion(+), 6 deletions(-) diff --git a/src/libvlc-common.c b/src/libvlc-common.c index 4820619a4e..2cd9d67aab 100644 --- a/src/libvlc-common.c +++ b/src/libvlc-common.c @@ -158,14 +158,12 @@ libvlc_int_t * libvlc_InternalCreate( void ) /* Now that the thread system is initialized, we don't have much, but * at least we have variables */ vlc_mutex_t *lock = var_AcquireMutex( "libvlc" ); - if( !p_libvlc_global->b_ready ) + if( i_instances == 0 ) { /* Guess what CPU we have */ cpu_flags = CPUCapabilities(); /* The module bank will be initialized later */ p_libvlc_global->p_module_bank = NULL; - - p_libvlc_global->b_ready = true; } /* Allocate a libvlc instance object */ diff --git a/src/libvlc.h b/src/libvlc.h index 3b25abb572..9b793a7adb 100644 --- a/src/libvlc.h +++ b/src/libvlc.h @@ -109,8 +109,6 @@ struct libvlc_global_data_t { VLC_COMMON_MEMBERS - bool b_ready; ///< Initialization boolean - /* Object structure data */ int i_counter; ///< object counter int i_objects; ///< Attached objects count diff --git a/src/misc/threads.c b/src/misc/threads.c index 8b0b3b9e56..5abe974432 100644 --- a/src/misc/threads.c +++ b/src/misc/threads.c @@ -151,7 +151,6 @@ int vlc_threads_init( void ) } /* We should be safe now. Do all the initialization stuff we want. */ - p_root->b_ready = false; vlc_threadvar_create( p_root, &msg_context_global_key ); } i_initializations++; -- 2.39.5