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

Commit 10031720 authored by Richard LIU's avatar Richard LIU
Browse files

Shutdown: fix timeout issue when shundown radios

For multisim case, before in a loop checking every phone:
"radioOff = radioOff && !mphone.isRadioOn(i)", set radioOff
variable as true first.

CRs-Fixed: 657385
Change-Id: I4ef102b297ca1f293eca0b5110c06b7650b20ed5
parent 85d0f004
Loading
Loading
Loading
Loading
+6 −3
Original line number Diff line number Diff line
@@ -556,10 +556,13 @@ public final class ShutdownThread extends Thread {
                            if (MSimTelephonyManager.getDefault().isMultiSimEnabled()) {
                                final ITelephonyMSim mphone = ITelephonyMSim.Stub.asInterface(
                                        ServiceManager.checkService("phone_msim"));
                                radioOff = true;
                                if (mphone != null) {
                                    for (int i = 0; i < MSimTelephonyManager.getDefault().
                                            getPhoneCount(); i++) {
                                        radioOff = radioOff && !mphone.isRadioOn(i);
                                    }
                                }
                            } else {
                                radioOff = !phone.isRadioOn();
                            }