Closed Bug 947086 Opened 7 years ago Closed 7 years ago
[Dialer] Dialer may call CDMA-specific bluetooth functions on non-CDMA phone
BluetoothHfpManager::AnswerWaitingCall() is a CDMA-specific function. holdAndAnswer() in calls_handler.js may call btHelper.answerWaitingCall(); in non-CDMA phone and trigger the assertion "MOZ_ASSERT(mPhoneType == PhoneType::CDMA)" in BluetoothHfpManager::AnswerWaitingCall(). The bug may crashes B2G when user hold a phone call on non-CDMA phone even the BT is unconnected to any devices.
Correction: The bug cause the assertion failed but it wouldn't crash B2G in release build.
Severity: major → normal
Hi Etienne, As per my understanding,it looks to be a small fix in Calls_handler.js I can work on this issue. Please assign to me in case no one is working.
Mukesh, Just click 'take' in 'Assign To:' field to take this bug, and ask for Etienne's review once you've done the fix. Thanks.
assigning to Mukesh as per his request
Assignee: nobody → mukeshk1990
(In reply to Mukesh kumar from comment #2) > Hi Etienne, > > As per my understanding,it looks to be a small fix in Calls_handler.js > I can work on this issue. > Please assign to me in case no one is working. Awesome :)
Hi, Please check if this pull request can fix the issue. https://github.com/mozilla-b2g/gaia/pull/15668 Thank you.
Comment on attachment 8364865 [details] Pointer to Pull Request.html The code change looks good, but we need to add a unit test. You can find some inspiration on how to test the |holdAndAnswer()| function here , how to test the bluetooth interactions there , and for the CDMA case you can look here . Cheers!  https://github.com/mozilla-b2g/gaia/blob/master/apps/communications/dialer/test/unit/calls_handler_test.js#L540-544  https://github.com/mozilla-b2g/gaia/blob/master/apps/communications/dialer/test/unit/calls_handler_test.js#L640-645  https://github.com/mozilla-b2g/gaia/blob/master/apps/communications/dialer/test/unit/calls_handler_test.js#L265-274
Hi Etienne, Thanks for your help. Updated pull request with test case added. Thank you.
Comment on attachment 8365972 [details] Pointer to Pull Request.html All good, thank!
Attachment #8365972 - Flags: review?(etienne) → review+
Hi, Please merge the patch to master. The patch is reviewed and good to merge.
Just restarted the failing travis job, will land as soon as it's green.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Request 1.3? per bug 979733 comment 5.
Cert blocker. 1.3+.
blocking-b2g: --- → 1.3+
Please request approval-gaia-v1.3 on this patch when this is ready for uplift.
Mukesh/Etienne, can you help uplift the gaia fix to 1.3? This bug becomes a 1.3 blocker since it fails BT certification test (bug 979733).
I dont have the permission to uplift this to v1.3 train. Etienne, Can you help uplifting this to 1.3? Thanks!
You need to log in before you can comment on or make changes to this bug.