[vlc-commits] mkv: fix missing unlock (cid #1047148)

Rémi Duraffort git at videolan.org
Sat Jul 13 15:31:27 CEST 2013


vlc/vlc-2.1 | branch: master | Rémi Duraffort <ivoire at videolan.org> | Sat Jul 13 10:18:36 2013 +0200| [fcf3e96385269e92d6db9b9ca20e4d61c1175d91] | committer: Jean-Baptiste Kempf

mkv: fix missing unlock (cid #1047148)

(cherry picked from commit 95a610fd5b7f034d2d10d86847a630d7902ec4fd)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.1.git/?a=commit;h=fcf3e96385269e92d6db9b9ca20e4d61c1175d91
---

 modules/demux/mkv/mkv.cpp |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/modules/demux/mkv/mkv.cpp b/modules/demux/mkv/mkv.cpp
index 88b9d03..7dc7e25 100644
--- a/modules/demux/mkv/mkv.cpp
+++ b/modules/demux/mkv/mkv.cpp
@@ -674,7 +674,11 @@ static int Demux( demux_t *p_demux)
 
     virtual_segment_c  *p_vsegment = p_sys->p_current_segment;
     matroska_segment_c *p_segment = p_vsegment->CurrentSegment();
-    if ( p_segment == NULL ) return 0;
+    if ( p_segment == NULL )
+    {
+        vlc_mutex_unlock( &p_sys->lock_demuxer );
+        return 0;
+    }
     int                i_block_count = 0;
     int                i_return = 0;
 



More information about the vlc-commits mailing list