Closed Bug 1357287 Opened 9 years ago Closed 9 years ago

Crash in java.lang.RuntimeException: cannot get MediaCodecList at android.media.MediaCodecList.native_getCodecCount(Native Method)

Categories

(Firefox for Android Graveyard :: Audio/Video, defect, P1)

Unspecified
Android
defect

Tracking

(firefox-esr52 unaffected, firefox53 wontfix, firefox54 fixed, firefox55 fixed)

RESOLVED FIXED
Firefox 55
Tracking Status
firefox-esr52 --- unaffected
firefox53 --- wontfix
firefox54 --- fixed
firefox55 --- fixed

People

(Reporter: n.nethercote, Assigned: esawin)

References

Details

(Keywords: crash)

Crash Data

Attachments

(1 file, 1 obsolete file)

This bug was filed from the Socorro interface and is report bp-523303de-52cb-4c5e-8768-20b442170415. ============================================================= Longstanding crash: > product version count perc installations > FennecAndroid 52.0.2 366 83.9% 108 > FennecAndroid 53.0 27 6.2% 5 > FennecAndroid 53.0b11 27 6.2% 8 > FennecAndroid 54.0a2 11 2.5% 6 > FennecAndroid 53.0b9 5 1.1% 1 Java stack trace: > java.lang.RuntimeException: cannot get MediaCodecList > at android.media.MediaCodecList.native_getCodecCount(Native Method) > at android.media.MediaCodecList.initCodecList(MediaCodecList.java:82) > at android.media.MediaCodecList.getCodecCount(MediaCodecList.java:43) > at org.mozilla.gecko.util.HardwareCodecCapabilityUtils.findDecoderCodecInfoForMimeType(HardwareCodecCapabilityUtils.java:43) > at org.mozilla.gecko.mozglue.GeckoLoader.nativeRun(Native Method) > at org.mozilla.gecko.GeckoThread.run(GeckoThread.java:583) jchen, any ideas?
Flags: needinfo?(nchen)
Flags: needinfo?(nchen) → needinfo?(esawin)
This looks like an Android bug to me on certain devices (mostly based on the "universal8890" SoC): https://android.googlesource.com/platform/frameworks/base/+/master/media/jni/android_media_MediaCodecList.cpp#39 I don't think we can do much here, so we should probably just block the media playback. Want me to investigate more or forward it to the media or Android team?
Assignee: nobody → esawin
Flags: needinfo?(esawin)
Attachment #8859278 - Flags: review?(snorp)
Comment on attachment 8859278 [details] [diff] [review] 0001-Bug-1357287-1.0-Catch-and-ignore-runtime-exception-d.patch Review of attachment 8859278 [details] [diff] [review]: ----------------------------------------------------------------- ::: mobile/android/geckoview/src/main/java/org/mozilla/gecko/util/HardwareCodecCapabilityUtils.java @@ +41,5 @@ > @WrapForJNI > public static boolean findDecoderCodecInfoForMimeType(String aMimeType) { > + int numCodecs = 0; > + try { > + numCodecs = MediaCodecList.getCodecCount(); This looks pretty strange without knowing about this bug, so maybe reference it in a comment.
Attachment #8859278 - Flags: review?(snorp) → review+
Priority: -- → P1
Added error logging.
Attachment #8859278 - Attachment is obsolete: true
Attachment #8859754 - Flags: review+
Pushed by esawin@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/72812cf49ddf [1.1] Catch and ignore runtime exception during media codec query. r=snorp
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 55
Seems worth a Beta nomination?
Flags: needinfo?(esawin)
Comment on attachment 8859754 [details] [diff] [review] 0001-Bug-1357287-1.1-Catch-and-ignore-runtime-exception-d.patch Approval Request Comment [Feature/Bug causing the regression]: N/A. [User impact if declined]: Crash on media playback. [Is this code covered by automated tests?]: No, we don't simulated Android system failures. [Has the fix been verified in Nightly?]: So far there are no crash reports on 55. [Needs manual test from QE? If yes, steps to reproduce]: N/A. [List of other uplifts needed for the feature/fix]: None. [Is the change risky?]: No. [Why is the change risky/not risky?]: It only handles an exception thrown by Android. Instead of crashing, we break media playback. [String changes made/needed]: None.
Flags: needinfo?(esawin)
Attachment #8859754 - Flags: approval-mozilla-beta?
Comment on attachment 8859754 [details] [diff] [review] 0001-Bug-1357287-1.1-Catch-and-ignore-runtime-exception-d.patch Fix a crash. Beta54+. Should be in 54 beta 6 for mobile.
Attachment #8859754 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Product: Firefox for Android → Firefox for Android Graveyard
See Also: → 1844622
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: