Add missing call and rename getErrorCodeForMediaDrmErrorCode
PiperOrigin-RevId: 383251000
This commit is contained in:
parent
6dbc1eb189
commit
5b2e854344
@ -1116,7 +1116,7 @@ public final class C {
|
|||||||
private static final int ERROR_PROVISIONING_RETRY = 28;
|
private static final int ERROR_PROVISIONING_RETRY = 28;
|
||||||
|
|
||||||
@PlaybackException.ErrorCode
|
@PlaybackException.ErrorCode
|
||||||
public static int getErrorCodeCorrespondingToPlatformDrmErrorCode(int mediaDrmErrorCode) {
|
public static int getErrorCodeForMediaDrmErrorCode(int mediaDrmErrorCode) {
|
||||||
switch (mediaDrmErrorCode) {
|
switch (mediaDrmErrorCode) {
|
||||||
case ERROR_PROVISIONING_CONFIG:
|
case ERROR_PROVISIONING_CONFIG:
|
||||||
case ERROR_PROVISIONING_PARSE:
|
case ERROR_PROVISIONING_PARSE:
|
||||||
|
@ -3120,10 +3120,12 @@ import java.util.concurrent.atomic.AtomicBoolean;
|
|||||||
}
|
}
|
||||||
|
|
||||||
@DoNotInline
|
@DoNotInline
|
||||||
|
@ErrorCode
|
||||||
public static int mediaDrmStateExceptionToErrorCode(Throwable throwable) {
|
public static int mediaDrmStateExceptionToErrorCode(Throwable throwable) {
|
||||||
@Nullable
|
@Nullable
|
||||||
String diagnosticsInfo = ((MediaDrm.MediaDrmStateException) throwable).getDiagnosticInfo();
|
String diagnosticsInfo = ((MediaDrm.MediaDrmStateException) throwable).getDiagnosticInfo();
|
||||||
return Util.getErrorCodeFromPlatformDiagnosticsInfo(diagnosticsInfo);
|
int drmErrorCode = Util.getErrorCodeFromPlatformDiagnosticsInfo(diagnosticsInfo);
|
||||||
|
return C.getErrorCodeForMediaDrmErrorCode(drmErrorCode);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1302,7 +1302,7 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
|
|||||||
}
|
}
|
||||||
} catch (CryptoException e) {
|
} catch (CryptoException e) {
|
||||||
throw createRendererException(
|
throw createRendererException(
|
||||||
e, inputFormat, C.getErrorCodeCorrespondingToPlatformDrmErrorCode(e.getErrorCode()));
|
e, inputFormat, C.getErrorCodeForMediaDrmErrorCode(e.getErrorCode()));
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -1373,7 +1373,7 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
|
|||||||
}
|
}
|
||||||
} catch (CryptoException e) {
|
} catch (CryptoException e) {
|
||||||
throw createRendererException(
|
throw createRendererException(
|
||||||
e, inputFormat, C.getErrorCodeCorrespondingToPlatformDrmErrorCode(e.getErrorCode()));
|
e, inputFormat, C.getErrorCodeForMediaDrmErrorCode(e.getErrorCode()));
|
||||||
}
|
}
|
||||||
|
|
||||||
resetInputBuffer();
|
resetInputBuffer();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user