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

Commit 66fba601 authored by Tomasz Wasilczyk's avatar Tomasz Wasilczyk
Browse files

Fix remembering last known cell identity for data-only devices

Bug: 371632841
Test: CtsTelephonyTestCases:android.telephony.cts.TelephonyManagerTest#testGetLastKnownCellIdentity
Flag: EXEMPT bugfix
Change-Id: I2f4e90d5f2403aaf7b01c986371769d6ae44c696
parent c327962b
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -3802,7 +3802,11 @@ public class ServiceStateTracker extends Handler {
        mNewSS.setOutOfService(false);

        mCellIdentity = primaryCellIdentity;
        if (mSS.getState() == ServiceState.STATE_IN_SERVICE && primaryCellIdentity != null) {
        boolean isCsRegistered = mSS.getNetworkRegistrationInfo(NetworkRegistrationInfo.DOMAIN_CS,
                AccessNetworkConstants.TRANSPORT_TYPE_WWAN).isNetworkRegistered();
        boolean isPsRegistered = mSS.getNetworkRegistrationInfo(NetworkRegistrationInfo.DOMAIN_PS,
                AccessNetworkConstants.TRANSPORT_TYPE_WWAN).isNetworkRegistered();
        if (isCsRegistered || isPsRegistered) {
            mLastKnownCellIdentity = mCellIdentity;
            removeMessages(EVENT_RESET_LAST_KNOWN_CELL_IDENTITY);
        }