[vlc-commits] demux: mp4: ignore indirect index references for seek

Francois Cartegnie git at videolan.org
Tue Apr 30 15:32:41 CEST 2019


vlc/vlc-3.0 | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Fri Apr 26 09:57:04 2019 +0200| [ba725460f67f20dfaa26b3ae84b6c5fb37d64c62] | committer: Francois Cartegnie

demux: mp4: ignore indirect index references for seek

(cherry picked from commit 4c43606d400c3e23f76b63ea40a2853bb1cbfc06)

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

 modules/demux/mp4/mp4.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/modules/demux/mp4/mp4.c b/modules/demux/mp4/mp4.c
index 5912b3a0d5..ba862c8664 100644
--- a/modules/demux/mp4/mp4.c
+++ b/modules/demux/mp4/mp4.c
@@ -4696,6 +4696,8 @@ static int FragGetMoofBySidxIndex( demux_t *p_demux, mtime_t i_target_time,
     stime_t i_time = 0;
     for( uint16_t i=0; i<p_data->i_reference_count; i++ )
     {
+        if(p_data->p_items[i].b_reference_type != 0)
+            continue;
         if( i_time + p_data->p_items[i].i_subsegment_duration > i_target_time )
         {
             *pi_sampletime = MP4_rescale( i_time, p_data->i_timescale, CLOCK_FREQ );



More information about the vlc-commits mailing list