Asserts p_this on __vlc_mutex_init()
authorRafaël Carré <funman@videolan.org>
Wed, 12 Sep 2007 19:36:15 +0000 (19:36 +0000)
committerRafaël Carré <funman@videolan.org>
Wed, 12 Sep 2007 19:36:15 +0000 (19:36 +0000)
src/misc/threads.c

index ffd09f6..26c7000 100644 (file)
@@ -27,6 +27,7 @@
 #include <vlc/vlc.h>
 
 #include "libvlc.h"
 #include <vlc/vlc.h>
 
 #include "libvlc.h"
+#include <assert.h>
 
 #define VLC_THREADS_UNINITIALIZED  0
 #define VLC_THREADS_PENDING        1
 
 #define VLC_THREADS_UNINITIALIZED  0
 #define VLC_THREADS_PENDING        1
@@ -238,6 +239,7 @@ int __vlc_threads_end( vlc_object_t *p_this )
  *****************************************************************************/
 int __vlc_mutex_init( vlc_object_t *p_this, vlc_mutex_t *p_mutex )
 {
  *****************************************************************************/
 int __vlc_mutex_init( vlc_object_t *p_this, vlc_mutex_t *p_mutex )
 {
+    assert( p_this );
     p_mutex->p_this = p_this;
 
 #if defined( PTH_INIT_IN_PTH_H )
     p_mutex->p_this = p_this;
 
 #if defined( PTH_INIT_IN_PTH_H )