summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2018-10-24 03:05:02 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2018-10-24 03:05:02 +0000
commitb8c3b61022636c880f4e5a5e6a71430552025f98 (patch)
treef98025f1e9a0a59253cf73cf4f1defb4d80bf172
parent1e53f6b418d977186f945cd9d646f18f770db346 (diff)
parentaf3d0ee5e324c4222f9747ccccac207dab3ae49b (diff)
downloadethernet-pie-qpr2-release.tar.gz
Snap for 5087486 from af3d0ee5e324c4222f9747ccccac207dab3ae49b to pi-qpr2-releaseandroid-9.0.0_r35android-9.0.0_r34android-9.0.0_r33android-9.0.0_r32android-9.0.0_r31pie-qpr2-release
Change-Id: I5ee774fa258492c202c81f56eb85f019ded154b2
-rw-r--r--java/com/android/server/ethernet/EthernetNetworkFactory.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/java/com/android/server/ethernet/EthernetNetworkFactory.java b/java/com/android/server/ethernet/EthernetNetworkFactory.java
index de0a691..b35e3cf 100644
--- a/java/com/android/server/ethernet/EthernetNetworkFactory.java
+++ b/java/com/android/server/ethernet/EthernetNetworkFactory.java
@@ -33,6 +33,7 @@ import android.net.NetworkSpecifier;
import android.net.StringNetworkSpecifier;
import android.net.ip.IpClient;
import android.net.ip.IpClient.ProvisioningConfiguration;
+import android.net.util.InterfaceParams;
import android.os.Handler;
import android.text.TextUtils;
import android.util.Log;
@@ -329,7 +330,11 @@ public class EthernetNetworkFactory extends NetworkFactory {
// This cannot happen due to provisioning timeout, because our timeout is 0. It can only
// happen if we're provisioned and we lose provisioning.
stop();
- start();
+ // If the interface has disappeared provisioning will fail over and over again, so
+ // there is no point in starting again
+ if (null != InterfaceParams.getByName(name)) {
+ start();
+ }
}
void updateLinkProperties(LinkProperties linkProperties) {