Commit 85917d05 authored by Ilkka Ollakka's avatar Ilkka Ollakka

livehttp: add DISCONTINUITY on playlist if we have restarted stream

If provided initial-segment-number option, signal discontinuity so
player knows to reset timestamps etc for new segments.
parent f06ef3b4
......@@ -591,10 +591,11 @@ static int updateIndexAndDel( sout_access_out_t *p_access, sout_access_out_sys_t
}
if ( fprintf( fp, "#EXTM3U\n#EXT-X-TARGETDURATION:%zu\n#EXT-X-VERSION:3\n#EXT-X-ALLOW-CACHE:%s"
"%s\n#EXT-X-MEDIA-SEQUENCE:%"PRIu32"\n", p_sys->i_seglen,
"%s\n#EXT-X-MEDIA-SEQUENCE:%"PRIu32"\n%s", p_sys->i_seglen,
p_sys->b_caching ? "YES" : "NO",
p_sys->i_numsegs > 0 ? "" : b_isend ? "\n#EXT-X-PLAYLIST-TYPE:VOD" : "\n#EXT-X-PLAYLIST-TYPE:EVENT",
i_firstseg ) < 0 )
i_firstseg, ((p_sys->i_initial_segment > 1) && (p_sys->i_initial_segment == i_firstseg)) ? "#EXT-X-DISCONTINUITY\n" : ""
) < 0 )
{
free( psz_idxTmp );
fclose( fp );
......
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