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

Commit e9c51bf2 authored by Jack Yu's avatar Jack Yu Committed by android-build-merger
Browse files

Merge "Re-add check for metered APNs regardless of IWLAN"

am: b97daaf5

Change-Id: Iefc7b95ba3d51a07184c56378c45115dd05448dc
parents 497ee53e b97daaf5
Loading
Loading
Loading
Loading
+2 −5
Original line number Original line Diff line number Diff line
@@ -1399,11 +1399,8 @@ public class DcTracker extends Handler {
        // At this point, if data is not allowed, it must be because of the soft reasons. We
        // At this point, if data is not allowed, it must be because of the soft reasons. We
        // should start to check some special conditions that data will be allowed.
        // should start to check some special conditions that data will be allowed.
        if (!reasons.allowed()) {
        if (!reasons.allowed()) {
            // If the device is on IWLAN, then all data should be unmetered. Check if the transport
            // Check if the transport is WLAN ie wifi (for AP-assisted mode devices)
            // is WLAN (for AP-assisted mode devices), or RAT equals IWLAN (for legacy mode devices)
            if (mTransportType == AccessNetworkConstants.TRANSPORT_TYPE_WLAN) {
            if (mTransportType == AccessNetworkConstants.TRANSPORT_TYPE_WLAN
                    || (mPhone.getTransportManager().isInLegacyMode()
                    && dataRat == ServiceState.RIL_RADIO_TECHNOLOGY_IWLAN)) {
                reasons.add(DataAllowedReasonType.UNMETERED_APN);
                reasons.add(DataAllowedReasonType.UNMETERED_APN);
            // Or if the data is on cellular, and the APN type is determined unmetered by the
            // Or if the data is on cellular, and the APN type is determined unmetered by the
            // configuration.
            // configuration.