[vlc-commits] httplive: check segment gap on last segment number instead of the segment number of last playlist load
Ilkka Ollakka
git at videolan.org
Mon Aug 26 15:43:07 CEST 2013
vlc | branch: master | Ilkka Ollakka <ileoo at videolan.org> | Mon Aug 26 16:08:23 2013 +0300| [7fa797f3ec9ef00f1f03d531687b40cab582ba9e] | committer: Ilkka Ollakka
httplive: check segment gap on last segment number instead of the segment number of last playlist load
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7fa797f3ec9ef00f1f03d531687b40cab582ba9e
---
modules/stream_filter/httplive.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/modules/stream_filter/httplive.c b/modules/stream_filter/httplive.c
index 5f3a204..be3d5ed 100644
--- a/modules/stream_filter/httplive.c
+++ b/modules/stream_filter/httplive.c
@@ -739,7 +739,9 @@ static int parse_MediaSequence(stream_t *s, hls_stream_t *hls, char *p_read)
if (s->p_sys->b_live)
{
hls_stream_t *last = hls_GetLast(s->p_sys->hls_stream);
- if ((last->sequence < sequence) && (sequence - last->sequence != 1))
+ segment_t *last_segment = segment_GetSegment( last, vlc_array_count( last->segments ) - 1 );
+ if ( ( last_segment->sequence < sequence) &&
+ ( sequence - last_segment->sequence >= 1 ))
msg_Err(s, "EXT-X-MEDIA-SEQUENCE gap in playlist (new=%d, old=%d)",
sequence, last->sequence);
}
More information about the vlc-commits
mailing list