mirror of
https://github.com/moonlight-stream/moonlight-android.git
synced 2026-10-20 15:27:18 +00:00
Allow recovery of IllegalStateExceptions for older versions of Android
This commit is contained in:
1 parent
f216834df7
commit
bc97db893a
1 file changed
+8
@@ -610,6 +610,14 @@ public class MediaCodecDecoderRenderer extends VideoDecoderRenderer implements C
|
||||
}
|
||||
}
|
||||
|
||||
// If we got here, this is most likely an IllegalStateException which was used prior to L
|
||||
// to indicate codec errors (unexpected transition to the error state). Recovery from this
|
||||
// requires a full decoder reset.
|
||||
if (codecRecoveryAttempts < CR_MAX_TRIES) {
|
||||
needsReset = true;
|
||||
return false;
|
||||
}
|
||||
|
||||
// Only throw if we're not stopping and aren't in the middle of codec recovery
|
||||
if (!stopping && !needsReset && !needsRestart) {
|
||||
//
|
||||
|
||||
Reference in new issue
Block a user