* libvlc.h: hopefully fix a few warnings.
authorAntoine Cellerier <dionoea@videolan.org>
Sun, 20 May 2007 14:42:13 +0000 (14:42 +0000)
committerAntoine Cellerier <dionoea@videolan.org>
Sun, 20 May 2007 14:42:13 +0000 (14:42 +0000)
* win32_specific.c, threads.c: fix win32 compilation.

src/libvlc.h
src/misc/threads.c
src/misc/win32_specific.c

index 5c0fac3..8516a90 100644 (file)
@@ -74,7 +74,8 @@ struct libvlc_global_data_t
 #endif
 };
 
-static inline libvlc_global_data_t *vlc_global( vlc_object_t *p_this )
+#define vlc_global( a ) __vlc_global( VLC_OBJECT( a ) )
+static inline libvlc_global_data_t *__vlc_global( vlc_object_t *p_this )
 {
     return (libvlc_global_data_t *)p_this->p_libvlc_global;
 }
index 26b8819..4d67bdb 100644 (file)
@@ -74,6 +74,8 @@ int __vlc_threads_init( vlc_object_t *p_this )
 #elif defined( ST_INIT_IN_ST_H )
 #elif defined( UNDER_CE )
 #elif defined( WIN32 )
+    b_fast_mutex = config_GetInt( p_this, "fast-mutex" );
+    i_win9x_cv = config_GetInt( p_this, "win9x-cv-method" );
 #elif defined( HAVE_KERNEL_SCHEDULER_H )
 #elif defined( PTHREAD_COND_T_IN_PTHREAD_H )
     pthread_mutex_lock( &once_mutex );
index 7ca7757..deb7208 100644 (file)
@@ -121,9 +121,6 @@ LRESULT CALLBACK WMCOPYWNDPROC( HWND, UINT, WPARAM, LPARAM );
 void system_Configure( libvlc_int_t *p_this, int *pi_argc, char *ppsz_argv[] )
 {
 #if !defined( UNDER_CE )
-    p_this->p_libvlc_global->b_fast_mutex = config_GetInt( p_this, "fast-mutex" );
-    p_this->p_libvlc_global->i_win9x_cv = config_GetInt( p_this, "win9x-cv-method" );
-
     /* Raise default priority of the current process */
 #ifndef ABOVE_NORMAL_PRIORITY_CLASS
 #   define ABOVE_NORMAL_PRIORITY_CLASS 0x00008000