Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit baa82ef7 authored by Jordan Liu's avatar Jordan Liu Committed by chen xu
Browse files

Add null check for mIccRecords

This will prevent process crashes temporarily as we try to root-cause
the issue.

Bug: 112434705
Test: atest FrameworksTelephonyTests
Change-Id: Icbee98a87319fcb2632e275f25fd8f7789a42d6d
Merged-in: Icbee98a87319fcb2632e275f25fd8f7789a42d6d
parent 49d59777
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -167,7 +167,11 @@ public class CarrierResolver extends Handler {
        if (DBG) logd("handleMessage: " + msg.what);
        switch (msg.what) {
            case SIM_LOAD_EVENT:
                if (mIccRecords != null) {
                    mSpn = mIccRecords.getServiceProviderName();
                } else {
                    loge("mIccRecords is null on SIM_LOAD_EVENT, could not get SPN");
                }
                mPreferApn = getPreferApn();
            case CARRIER_ID_DB_UPDATE_EVENT:
                loadCarrierMatchingRulesOnMccMnc();