]> git.sesse.net Git - vlc/commitdiff
* Fixed a deadlock (the vout unlocked a mutex locked by another thread,
authorChristophe Massiot <massiot@videolan.org>
Thu, 4 Jan 2001 18:47:18 +0000 (18:47 +0000)
committerChristophe Massiot <massiot@videolan.org>
Thu, 4 Jan 2001 18:47:18 +0000 (18:47 +0000)
grrrr, I'll kill someone) ;
* Put config.h in front of others in audio_decoder.c.

src/audio_decoder/audio_decoder.c
src/video_output/video_output.c

index 3ff05af0cf7b06d9af519bee5f1814223a52d7fa..a1752c5b761d1e5a20afdc296201d9bd0319a43b 100644 (file)
@@ -2,7 +2,7 @@
  * audio_decoder.c: MPEG audio decoder thread
  *****************************************************************************
  * Copyright (C) 1999, 2000 VideoLAN
- * $Id: audio_decoder.c,v 1.43 2000/12/27 18:35:45 massiot Exp $
+ * $Id: audio_decoder.c,v 1.44 2001/01/04 18:47:18 massiot Exp $
  *
  * Authors: Michel Kaempf <maxx@via.ecp.fr>
  *          Michel Lespinasse <walken@via.ecp.fr>
@@ -44,9 +44,9 @@
 #include <sys/uio.h>                                            /* "input.h" */
 #include <netinet/in.h>                                             /* ntohl */
 
-#include "threads.h"
-#include "common.h"
 #include "config.h"
+#include "common.h"
+#include "threads.h"
 #include "mtime.h"
 #include "plugins.h"
 #include "debug.h"                                      /* "input_netlist.h" */
index cfb1e5545b62388c990fa4b3ba16a08608d870bc..c95229fa3022af8e9c06348dd9fc6fd398e92a9d 100644 (file)
@@ -256,7 +256,7 @@ vout_thread_t * vout_CreateThread   ( char *psz_display, int i_root_window,
     vlc_mutex_init( &p_vout->picture_lock );
     vlc_mutex_init( &p_vout->subpicture_lock );
     vlc_mutex_init( &p_vout->change_lock );
-    vlc_mutex_lock( &p_vout->change_lock );
+
     if( vlc_thread_create( &p_vout->thread_id, "video output",
                            (void *) RunThread, (void *) p_vout) )
     {
@@ -912,6 +912,8 @@ static int InitThread( vout_thread_t *p_vout )
     /* Update status */
     *p_vout->pi_status = THREAD_START;
 
+    vlc_mutex_lock( &p_vout->change_lock );
+
 #ifdef STATS
     p_vout->c_loops = 0;
 #endif