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

Commit f2d89cda authored by Ricardo Cerqueira's avatar Ricardo Cerqueira
Browse files

RIL: qcom: Stop the card handler thread when radio is off

Ensure the SIM is reinitialized when the radio is turned on, to
prevent state mismatches from dirty variables.
Fixes occasional crashes while entering/leaving airplane mode.

Change-Id: Ib8ca81eee00fd4a983f63190f51f5f27fd0947b6
parent a6310907
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -613,6 +613,10 @@ public class QualcommNoSimReadyRIL extends RIL implements CommandsInterface {
        switch (stateCode) {
            case RIL_INT_RADIO_OFF:
                radioState = CommandsInterface.RadioState.RADIO_OFF;
                if (mIccHandler != null) {
                    mIccThread = null;
                    mIccHandler = null;
                }
                break;
            case RIL_INT_RADIO_UNAVALIABLE:
                radioState = CommandsInterface.RadioState.RADIO_UNAVAILABLE;