Skip to content

Commit 903fddc

Browse files
matvp91avelad
authored andcommitted
fix: Bail out on other decodingInfos when we found a preferred and supported one. (#8829)
Pick a multi DRM asset, set `preferredKeySystems` to prefer PlayReady over Widevine and run on a device that does not support PlayReady (eg; Chrome). A `REQUESTED_KEY_SYSTEM_CONFIG_UNAVAILABLE` is thrown. This is due to the logic in `getDecodingInfosForVariants` where we bail out on probing other decodingInfos when we found a prefered one, but we didn't check whether it was supported or not. As a result, Widevine was never checked and PlayReady was left marked as unsupported.
1 parent 1f42cef commit 903fddc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/util/stream_utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -736,7 +736,7 @@ shaka.util.StreamUtils = class {
736736
await shaka.util.StreamUtils.getDecodingInfosForVariant_(
737737
variant, configs);
738738
}
739-
if (variant.decodingInfos.length) {
739+
if (variant.decodingInfos.some((d) => d.supported)) {
740740
keySystemSatisfied = true;
741741
}
742742
} // for (const variant of variants)

0 commit comments

Comments
 (0)