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

Commit c920c836 authored by Robert Greenwalt's avatar Robert Greenwalt Committed by Android Git Automerger
Browse files

am 7725180c: Prefer the preferred APN for all types it supports

* commit '7725180c':
  Prefer the preferred APN for all types it supports
parents d6c131dc 7725180c
Loading
Loading
Loading
Loading
+14 −15
Original line number Diff line number Diff line
@@ -2322,8 +2322,8 @@ public final class GsmDataConnectionTracker extends DataConnectionTracker {
        String operator = mPhone.mIccRecords.getOperatorNumeric();
        int networkType = mPhone.getServiceState().getNetworkType();

        if (requestedApnType.equals(Phone.APN_TYPE_DEFAULT)) {
            if (canSetPreferApn && mPreferredApn != null) {
        if (canSetPreferApn && mPreferredApn != null &&
                mPreferredApn.canHandleType(requestedApnType)) {
            if (DBG) {
                log("buildWaitingApns: Preferred APN:" + operator + ":"
                        + mPreferredApn.numeric + ":" + mPreferredApn);
@@ -2344,7 +2344,6 @@ public final class GsmDataConnectionTracker extends DataConnectionTracker {
                mPreferredApn = null;
            }
        }
        }
        if (mAllApns != null) {
            for (ApnSetting apn : mAllApns) {
                if (apn.canHandleType(requestedApnType)) {