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

Commit 7d137ee9 authored by Sukanya Rajkhowa's avatar Sukanya Rajkhowa
Browse files

Cleanup connections for APNs that are not connected

- After disabling a network, ConnectivityService tears down
  the data connection
- However, for APNs that are in Connecting, Failed or Retry
  state, ConnectivityService will not do that because the NetworkAgent
  is created only when a DataConnection goes into Active State.
  Take care of this case by explicitly tearing down the data connection

CRs-Fixed: 914669

Change-Id: I87f286cb8b5fe5c6a33e8c5cf53da7bca8d7aa2b
parent 30e06b2c
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1649,7 +1649,8 @@ public class DcTracker extends DcTrackerBase {
                // request goes away.  This applies to both CDMA and GSM because they both
                // can declare the DUN APN sharable by default traffic, thus still satisfying
                // those requests and not torn down organically.
                if (apnContext.getApnType() == PhoneConstants.APN_TYPE_DUN && teardownForDun()) {
                if ((apnContext.getApnType() == PhoneConstants.APN_TYPE_DUN && teardownForDun())
                        || apnContext.getState() != DctConstants.State.CONNECTED) {
                    cleanup = true;
                } else {
                    cleanup = false;