Merge "Support "dumpsys connectivity tethering"" am: df8b274a65 am: 06e6033327
am: ff8b93f815 Change-Id: I68ff0810e4109c52e1d594a4b75fc768570ef59d
This commit is contained in:
@@ -180,6 +180,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
|
||||
|
||||
public static final String DIAG_ARG = "--diag";
|
||||
public static final String SHORT_ARG = "--short";
|
||||
public static final String TETHERING_ARG = "tethering";
|
||||
|
||||
private static final boolean DBG = true;
|
||||
private static final boolean VDBG = false;
|
||||
@@ -1842,7 +1843,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
|
||||
|
||||
private boolean argsContain(String[] args, String target) {
|
||||
for (String arg : args) {
|
||||
if (arg.equals(target)) return true;
|
||||
if (target.equals(arg)) return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
@@ -1873,6 +1874,9 @@ public class ConnectivityService extends IConnectivityManager.Stub
|
||||
if (argsContain(args, DIAG_ARG)) {
|
||||
dumpNetworkDiagnostics(pw);
|
||||
return;
|
||||
} else if (argsContain(args, TETHERING_ARG)) {
|
||||
mTethering.dump(fd, pw, args);
|
||||
return;
|
||||
}
|
||||
|
||||
pw.print("NetworkFactories for:");
|
||||
|
||||
Reference in New Issue
Block a user