Bug 869778 - Part 4: PhoneNumberUtils changes for iccInfo. r=gwagner
authorEdgar Chen <echen@mozilla.com>
Tue, 20 Aug 2013 17:59:08 +0800
changeset 158451 65938897536e4f6a39568ebe442e5f2eafe49f08
parent 158450 2d4c400127af9d432cd3cefb874479784a9b5017
child 158452 1eebc1edf40a4cd2be3cff8f75d34d43b99d8e9c
push id2961
push userlsblakk@mozilla.com
push dateMon, 28 Oct 2013 21:59:28 +0000
treeherdermozilla-beta@73ef4f13486f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgwagner
bugs869778
milestone26.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 869778 - Part 4: PhoneNumberUtils changes for iccInfo. r=gwagner
dom/phonenumberutils/PhoneNumberUtils.jsm
--- a/dom/phonenumberutils/PhoneNumberUtils.jsm
+++ b/dom/phonenumberutils/PhoneNumberUtils.jsm
@@ -43,17 +43,17 @@ this.PhoneNumberUtils = {
     // Get network mcc
     let voice = mobileConnection.voiceConnectionInfo;
     if (voice && voice.network && voice.network.mcc) {
       mcc = voice.network.mcc;
     }
 
     // Get SIM mcc
     let iccInfo = mobileConnection.iccInfo;
-    if (!mcc && iccInfo.mcc) {
+    if (!mcc && iccInfo && iccInfo.mcc) {
       mcc = iccInfo.mcc;
     }
 
     // Attempt to grab last known sim mcc from prefs
     if (!mcc) {
       try {
         mcc = Services.prefs.getCharPref("ril.lastKnownSimMcc");
       } catch (e) {}