Revert "Addressing comments for http://ag/7700679."

am: a293c0644b

Change-Id: I56e7736ced431a5dcd78a6a258abfad09745d25e
This commit is contained in:
Benedict Wong
2019-06-07 02:33:26 -07:00
committed by android-build-merger
2 changed files with 26 additions and 93 deletions

View File

@@ -4394,7 +4394,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
// the underlyingNetworks list.
if (underlyingNetworks == null) {
NetworkAgentInfo defaultNai = getDefaultNetwork();
if (defaultNai != null) {
if (defaultNai != null && defaultNai.linkProperties != null) {
underlyingNetworks = new Network[] { defaultNai.network };
}
}
@@ -4402,7 +4402,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
List<String> interfaces = new ArrayList<>();
for (Network network : underlyingNetworks) {
LinkProperties lp = getLinkProperties(network);
if (lp != null && !TextUtils.isEmpty(lp.getInterfaceName())) {
if (lp != null) {
interfaces.add(lp.getInterfaceName());
}
}