[vlc-commits] demux:mkv: don't overwrite a seekpoint using a lower trusted level

Steve Lhomme git at videolan.org
Sun Aug 6 22:26:10 CEST 2017


vlc | branch: master | Steve Lhomme <robUx4 at videolabs.io> | Fri Aug  4 14:29:03 2017 +0200| [6f3e79d176fff00fd765aa76bca91a5ba324fa8e] | committer: Jean-Baptiste Kempf

demux:mkv: don't overwrite a seekpoint using a lower trusted level

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

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

 modules/demux/mkv/matroska_segment_seeker.cpp | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/modules/demux/mkv/matroska_segment_seeker.cpp b/modules/demux/mkv/matroska_segment_seeker.cpp
index c447ae3866..2887e45454 100644
--- a/modules/demux/mkv/matroska_segment_seeker.cpp
+++ b/modules/demux/mkv/matroska_segment_seeker.cpp
@@ -119,6 +119,9 @@ SegmentSeeker::add_seekpoint( track_id_t track_id, Seekpoint sp )
 
     if( it != seekpoints.end() && it->pts == sp.pts )
     {
+        if (sp.trust_level <= it->trust_level)
+            return;
+
         *it = sp;
     }
     else



More information about the vlc-commits mailing list