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

Commit 04e22225 authored by Pierre Imai's avatar Pierre Imai
Browse files

Log an event whenever we lose the default network.

Change-Id: Ia71865a90b2db5dc0d3ad627563a6b1f99686f04
parent 6b4e15b1
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -2206,6 +2206,12 @@ public class ConnectivityService extends IConnectivityManager.Stub
            }
            mLegacyTypeTracker.remove(nai, wasDefault);
            rematchAllNetworksAndRequests(null, 0);
            if (wasDefault && getDefaultNetwork() == null) {
                // Log that we lost the default network and there is no replacement.
                final int[] transportTypes = new int[0];
                ConnectivityServiceChangeEvent.logEvent(NETID_UNSET, nai.network.netId,
                        transportTypes);
            }
            if (nai.created) {
                // Tell netd to clean up the configuration for this network
                // (routing rules, DNS, etc).