Commit fc416105 authored by Batalov Vladislav's avatar Batalov Vladislav Committed by Commit Bot

Catch another exception from drm.

Android can throw an exception during checking scheme.
https://cs.android.com/android/platform/superproject/+/master:frameworks/base/media/jni/android_media_MediaDrm.cpp;l=987?q=throwExceptionAsNecessary
It seems like there is no reason to not catch it neither.

Change-Id: Ib6b1e889f3849a24372a0a3f0601c5f5193da9fc
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2401099Reviewed-by: default avatarMatthew Wolenetz <wolenetz@chromium.org>
Commit-Queue: Matthew Wolenetz <wolenetz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#805851}
parent 40d318a5
...@@ -442,13 +442,13 @@ public class MediaDrmBridge { ...@@ -442,13 +442,13 @@ public class MediaDrmBridge {
Log.i(TAG, "Create MediaDrmBridge with level %s and origin %s", securityLevel, Log.i(TAG, "Create MediaDrmBridge with level %s and origin %s", securityLevel,
securityOrigin); securityOrigin);
UUID cryptoScheme = getUUIDFromBytes(schemeUUID);
if (cryptoScheme == null || !MediaDrm.isCryptoSchemeSupported(cryptoScheme)) {
return null;
}
MediaDrmBridge mediaDrmBridge = null; MediaDrmBridge mediaDrmBridge = null;
try { try {
UUID cryptoScheme = getUUIDFromBytes(schemeUUID);
if (cryptoScheme == null || !MediaDrm.isCryptoSchemeSupported(cryptoScheme)) {
return null;
}
mediaDrmBridge = new MediaDrmBridge(cryptoScheme, requiresMediaCrypto, mediaDrmBridge = new MediaDrmBridge(cryptoScheme, requiresMediaCrypto,
nativeMediaDrmBridge, nativeMediaDrmStorageBridge); nativeMediaDrmBridge, nativeMediaDrmStorageBridge);
} catch (android.media.UnsupportedSchemeException e) { } catch (android.media.UnsupportedSchemeException e) {
......
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