Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(HLS): Mark first partial segment as independent always #5312

Merged
merged 3 commits into from
Jun 20, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion lib/hls/hls_parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -2915,7 +2915,11 @@ shaka.hls.HlsParser = class {
if (item.name == 'EXT-X-PRELOAD-HINT') {
partial.markAsPreload();
}
if (item.getAttributeValue('INDEPENDENT') != 'YES') {
// The spec doesn't say that we can assume INDEPENDENT=YES for the
// first partial segment. It does call the flag "optional", though, and
// that cases where there are no such flags on any partial segments, it
// is sensible to assume the first one is independent.
if (item.getAttributeValue('INDEPENDENT') != 'YES' && i > 0) {
joeyparrish marked this conversation as resolved.
Show resolved Hide resolved
partial.markAsNonIndependent();
}
partialSegmentRefs.push(partial);
Expand Down