[vlc-commits] demux: mkv: fix leak

Francois Cartegnie git at videolan.org
Wed Mar 12 19:51:38 CET 2014


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Mar 12 19:50:13 2014 +0100| [1a1169931a7e6c9e7c1a71da7e7e378b07b191ef] | committer: Francois Cartegnie

demux: mkv: fix leak

cid 1048915

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

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

diff --git a/modules/demux/mkv/matroska_segment.cpp b/modules/demux/mkv/matroska_segment.cpp
index c75eab5..1d6ccaa 100644
--- a/modules/demux/mkv/matroska_segment.cpp
+++ b/modules/demux/mkv/matroska_segment.cpp
@@ -991,6 +991,12 @@ void matroska_segment_c::Seek( mtime_t i_date, mtime_t i_time_offset, int64_t i_
             if( BlockGet( block, simpleblock, &b_key_picture, &b_discardable_picture, &i_block_duration ) )
             {
                 msg_Warn( &sys.demuxer, "cannot get block EOF?" );
+                while( p_first )
+                {
+                    spoint *tmp = p_first;
+                    p_first = p_first->p_next;
+                    delete tmp;
+                }
                 return;
             }
 



More information about the vlc-commits mailing list