Commit 66be1eaf authored by Francois Cartegnie's avatar Francois Cartegnie

demux: mp4: never match an empty fragment computing time offset

parent 1a0570b5
...@@ -4311,7 +4311,9 @@ static mtime_t LeafGetFragmentTimeOffset( demux_t *p_demux, mp4_fragment_t *p_fr ...@@ -4311,7 +4311,9 @@ static mtime_t LeafGetFragmentTimeOffset( demux_t *p_demux, mp4_fragment_t *p_fr
mp4_fragment_t *p_current = &p_demux->p_sys->moovfragment; mp4_fragment_t *p_current = &p_demux->p_sys->moovfragment;
while ( p_current != p_fragment ) while ( p_current != p_fragment )
{ {
i_base_scaledtime += p_current->i_duration; if ( p_current != &p_demux->p_sys->moovfragment ||
p_current->i_chunk_range_max_offset )
i_base_scaledtime += p_current->i_duration;
p_current = p_current->p_next; p_current = p_current->p_next;
} }
return i_base_scaledtime; return i_base_scaledtime;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment