Commit 955b873d authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

- Remove useless global variable

- Fix threading qualifier warnings
parent 41f75f96
...@@ -334,13 +334,13 @@ struct module_symbols_t ...@@ -334,13 +334,13 @@ struct module_symbols_t
int (*__vlc_threads_init_inner) (vlc_object_t *); int (*__vlc_threads_init_inner) (vlc_object_t *);
int (*__vlc_threads_end_inner) (vlc_object_t *); int (*__vlc_threads_end_inner) (vlc_object_t *);
int (*__vlc_mutex_init_inner) (vlc_object_t *, vlc_mutex_t *); int (*__vlc_mutex_init_inner) (vlc_object_t *, vlc_mutex_t *);
int (*__vlc_mutex_destroy_inner) (char *, int, vlc_mutex_t *); int (*__vlc_mutex_destroy_inner) (const char *, int, vlc_mutex_t *);
int (*__vlc_cond_init_inner) (vlc_object_t *, vlc_cond_t *); int (*__vlc_cond_init_inner) (vlc_object_t *, vlc_cond_t *);
int (*__vlc_cond_destroy_inner) (char *, int, vlc_cond_t *); int (*__vlc_cond_destroy_inner) (const char *, int, vlc_cond_t *);
int (*__vlc_thread_create_inner) (vlc_object_t *, char *, int, char *, void * ( * ) ( void * ), int, vlc_bool_t); int (*__vlc_thread_create_inner) (vlc_object_t *, const char *, int, const char *, void * ( * ) ( void * ), int, vlc_bool_t);
int (*__vlc_thread_set_priority_inner) (vlc_object_t *, char *, int, int); int (*__vlc_thread_set_priority_inner) (vlc_object_t *, const char *, int, int);
void (*__vlc_thread_ready_inner) (vlc_object_t *); void (*__vlc_thread_ready_inner) (vlc_object_t *);
void (*__vlc_thread_join_inner) (vlc_object_t *, char *, int); void (*__vlc_thread_join_inner) (vlc_object_t *, const char *, int);
void (*__vout_CopyPicture_inner) (vlc_object_t *p_this, picture_t *p_dst, picture_t *p_src); void (*__vout_CopyPicture_inner) (vlc_object_t *p_this, picture_t *p_dst, picture_t *p_src);
int (*__vout_InitPicture_inner) (vlc_object_t *p_this, picture_t *p_pic, uint32_t i_chroma, int i_width, int i_height, int i_aspect); int (*__vout_InitPicture_inner) (vlc_object_t *p_this, picture_t *p_pic, uint32_t i_chroma, int i_width, int i_height, int i_aspect);
int (*__vout_AllocatePicture_inner) (vlc_object_t *p_this, picture_t *p_pic, uint32_t i_chroma, int i_width, int i_height, int i_aspect); int (*__vout_AllocatePicture_inner) (vlc_object_t *p_this, picture_t *p_pic, uint32_t i_chroma, int i_width, int i_height, int i_aspect);
......
...@@ -31,13 +31,13 @@ ...@@ -31,13 +31,13 @@
VLC_EXPORT( int, __vlc_threads_init, ( vlc_object_t * ) ); VLC_EXPORT( int, __vlc_threads_init, ( vlc_object_t * ) );
VLC_EXPORT( int, __vlc_threads_end, ( vlc_object_t * ) ); VLC_EXPORT( int, __vlc_threads_end, ( vlc_object_t * ) );
VLC_EXPORT( int, __vlc_mutex_init, ( vlc_object_t *, vlc_mutex_t * ) ); VLC_EXPORT( int, __vlc_mutex_init, ( vlc_object_t *, vlc_mutex_t * ) );
VLC_EXPORT( int, __vlc_mutex_destroy, ( char *, int, vlc_mutex_t * ) ); VLC_EXPORT( int, __vlc_mutex_destroy, ( const char *, int, vlc_mutex_t * ) );
VLC_EXPORT( int, __vlc_cond_init, ( vlc_object_t *, vlc_cond_t * ) ); VLC_EXPORT( int, __vlc_cond_init, ( vlc_object_t *, vlc_cond_t * ) );
VLC_EXPORT( int, __vlc_cond_destroy, ( char *, int, vlc_cond_t * ) ); VLC_EXPORT( int, __vlc_cond_destroy, ( const char *, int, vlc_cond_t * ) );
VLC_EXPORT( int, __vlc_thread_create, ( vlc_object_t *, char *, int, char *, void * ( * ) ( void * ), int, vlc_bool_t ) ); VLC_EXPORT( int, __vlc_thread_create, ( vlc_object_t *, const char *, int, const char *, void * ( * ) ( void * ), int, vlc_bool_t ) );
VLC_EXPORT( int, __vlc_thread_set_priority, ( vlc_object_t *, char *, int, int ) ); VLC_EXPORT( int, __vlc_thread_set_priority, ( vlc_object_t *, const char *, int, int ) );
VLC_EXPORT( void, __vlc_thread_ready, ( vlc_object_t * ) ); VLC_EXPORT( void, __vlc_thread_ready, ( vlc_object_t * ) );
VLC_EXPORT( void, __vlc_thread_join, ( vlc_object_t *, char *, int ) ); VLC_EXPORT( void, __vlc_thread_join, ( vlc_object_t *, const char *, int ) );
/***************************************************************************** /*****************************************************************************
......
...@@ -49,19 +49,6 @@ static vlc_object_t *p_root; ...@@ -49,19 +49,6 @@ static vlc_object_t *p_root;
#elif defined( HAVE_CTHREADS_H ) #elif defined( HAVE_CTHREADS_H )
#endif #endif
/*****************************************************************************
* Global variable for named mutexes
*****************************************************************************/
typedef struct vlc_namedmutex_t vlc_namedmutex_t;
struct vlc_namedmutex_t
{
vlc_mutex_t lock;
char *psz_name;
int i_usage;
vlc_namedmutex_t *p_next;
};
/***************************************************************************** /*****************************************************************************
* vlc_threads_init: initialize threads system * vlc_threads_init: initialize threads system
***************************************************************************** *****************************************************************************
...@@ -304,7 +291,7 @@ int __vlc_mutex_init( vlc_object_t *p_this, vlc_mutex_t *p_mutex ) ...@@ -304,7 +291,7 @@ int __vlc_mutex_init( vlc_object_t *p_this, vlc_mutex_t *p_mutex )
/***************************************************************************** /*****************************************************************************
* vlc_mutex_destroy: destroy a mutex, inner version * vlc_mutex_destroy: destroy a mutex, inner version
*****************************************************************************/ *****************************************************************************/
int __vlc_mutex_destroy( char * psz_file, int i_line, vlc_mutex_t *p_mutex ) int __vlc_mutex_destroy( const char * psz_file, int i_line, vlc_mutex_t *p_mutex )
{ {
int i_result; int i_result;
/* In case of error : */ /* In case of error : */
...@@ -461,7 +448,7 @@ int __vlc_cond_init( vlc_object_t *p_this, vlc_cond_t *p_condvar ) ...@@ -461,7 +448,7 @@ int __vlc_cond_init( vlc_object_t *p_this, vlc_cond_t *p_condvar )
/***************************************************************************** /*****************************************************************************
* vlc_cond_destroy: destroy a condition, inner version * vlc_cond_destroy: destroy a condition, inner version
*****************************************************************************/ *****************************************************************************/
int __vlc_cond_destroy( char * psz_file, int i_line, vlc_cond_t *p_condvar ) int __vlc_cond_destroy( const char * psz_file, int i_line, vlc_cond_t *p_condvar )
{ {
int i_result; int i_result;
/* In case of error : */ /* In case of error : */
...@@ -519,8 +506,8 @@ int __vlc_cond_destroy( char * psz_file, int i_line, vlc_cond_t *p_condvar ) ...@@ -519,8 +506,8 @@ int __vlc_cond_destroy( char * psz_file, int i_line, vlc_cond_t *p_condvar )
* Note that i_priority is only taken into account on platforms supporting * Note that i_priority is only taken into account on platforms supporting
* userland real-time priority threads. * userland real-time priority threads.
*****************************************************************************/ *****************************************************************************/
int __vlc_thread_create( vlc_object_t *p_this, char * psz_file, int i_line, int __vlc_thread_create( vlc_object_t *p_this, const char * psz_file, int i_line,
char *psz_name, void * ( *func ) ( void * ), const char *psz_name, void * ( *func ) ( void * ),
int i_priority, vlc_bool_t b_wait ) int i_priority, vlc_bool_t b_wait )
{ {
int i_ret; int i_ret;
...@@ -645,7 +632,7 @@ int __vlc_thread_create( vlc_object_t *p_this, char * psz_file, int i_line, ...@@ -645,7 +632,7 @@ int __vlc_thread_create( vlc_object_t *p_this, char * psz_file, int i_line,
* vlc_thread_set_priority: set the priority of the current thread when we * vlc_thread_set_priority: set the priority of the current thread when we
* couldn't set it in vlc_thread_create (for instance for the main thread) * couldn't set it in vlc_thread_create (for instance for the main thread)
*****************************************************************************/ *****************************************************************************/
int __vlc_thread_set_priority( vlc_object_t *p_this, char * psz_file, int __vlc_thread_set_priority( vlc_object_t *p_this, const char * psz_file,
int i_line, int i_priority ) int i_line, int i_priority )
{ {
#if defined( PTH_INIT_IN_PTH_H ) || defined( ST_INIT_IN_ST_H ) #if defined( PTH_INIT_IN_PTH_H ) || defined( ST_INIT_IN_ST_H )
...@@ -707,7 +694,7 @@ void __vlc_thread_ready( vlc_object_t *p_this ) ...@@ -707,7 +694,7 @@ void __vlc_thread_ready( vlc_object_t *p_this )
/***************************************************************************** /*****************************************************************************
* vlc_thread_join: wait until a thread exits, inner version * vlc_thread_join: wait until a thread exits, inner version
*****************************************************************************/ *****************************************************************************/
void __vlc_thread_join( vlc_object_t *p_this, char * psz_file, int i_line ) void __vlc_thread_join( vlc_object_t *p_this, const char * psz_file, int i_line )
{ {
int i_ret = 0; int i_ret = 0;
......
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