Closed Bug 1168309 Opened 7 years ago Closed 7 years ago

[FFOS] Gonk's PDM cannot enter dormant state.

Categories

(Core :: Audio/Video, defect)

37 Branch
ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla41
Tracking Status
firefox41 --- fixed

People

(Reporter: bwu, Assigned: bwu)

References

Details

(Keywords: regression)

Attachments

(1 file, 1 obsolete file)

When playing some videos from browser and pushing the home key, PDM doesn't enter dormant and codec is not released.
User experience impacted: 
If user watch video from browsers and then push the home key to play a video file in video app, video app will show "Another app is currently using the video player".
Keywords: regression
This should be caused by the Bug 1163458.
The root cause is MOZ_GONK_MEDIACODEC is not defined dom/media, so READER_DORMANT_HEURISTIC will not be defined in [1] and subsequently MediaFormatReader's IsDormantNeeded()[2] returns false. 


[1]https://dxr.mozilla.org/mozilla-central/source/dom/media/MediaFormatReader.h#20
[2]https://dxr.mozilla.org/mozilla-central/source/dom/media/MediaFormatReader.cpp#1288
Root cause:
Per comment 2. 

Solution:
Add the define, MOZ_GONK_MEDIACODEC, to dom/media.
Attachment #8610472 - Flags: review?(cpearce)
Attachment #8610472 - Flags: review?(cpearce) → review+
Thanks for cpearce's review! 
Carry r+ from cpearce.
Attachment #8610472 - Attachment is obsolete: true
Attachment #8610985 - Flags: review+
Test results are all green.
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/a3a3e00caaff
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla41
You need to log in before you can comment on or make changes to this bug.