[vlc-commits] demux: mkv: fail the segment comparison if a segment UID is NULL

Steve Lhomme git at videolan.org
Tue May 29 12:08:31 CEST 2018


vlc/vlc-3.0 | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Tue May 29 11:07:49 2018 +0200| [c472668ff873cfe29281822b4548715fb7bb0368] | committer: Jean-Baptiste Kempf

demux: mkv: fail the segment comparison if a segment UID is NULL

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

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

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

diff --git a/modules/demux/mkv/matroska_segment.cpp b/modules/demux/mkv/matroska_segment.cpp
index d50bdf5b20..a99b298fb1 100644
--- a/modules/demux/mkv/matroska_segment.cpp
+++ b/modules/demux/mkv/matroska_segment.cpp
@@ -545,6 +545,8 @@ bool matroska_segment_c::CompareSegmentUIDs( const matroska_segment_c * p_item_a
         return false;
 
     p_tmp = static_cast<EbmlBinary *>( p_item_a->p_segment_uid );
+    if ( !p_tmp )
+        return false;
     if ( p_item_b->p_prev_segment_uid != NULL
           && *p_tmp == *p_item_b->p_prev_segment_uid )
         return true;



More information about the vlc-commits mailing list