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

Commit 41b96a97 authored by Ricardo Cerqueira's avatar Ricardo Cerqueira
Browse files

Fix sporadic crashes with MSIM devices and inactive SIMs

An MSIM device with a single inactive SIM (PIN locked, for instance)
can and frequently will get into a situation where it tries to set
ip invalid IDs (none have been assigned) as the "default" voice sub

Fixes CYNGNOS-2711

Change-Id: I7fcc1f42e5e74886192bbb5f8a74f3a69473e761
parent cbf3ace2
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -236,6 +236,10 @@ public final class PhoneAccountRegistrar {
        for (int i = 0; i < mState.accounts.size(); i++) {
            String id = mState.accounts.get(i).getAccountHandle().getId();

            if (id == null || id.equals("null") || TextUtils.isEmpty(id)) {
                continue;
            }

            // emergency account present return it
            if (id.equals("E")) {
                Log.i(this, "getUserSelVoicePhoneAccount, emergency account ");