Merge "Revert "Second pass tying into dns cache per interface""
This commit is contained in:
committed by
Android (Google) Code Review
commit
20da885caa
@@ -1468,32 +1468,6 @@ public class NetworkManagementService extends INetworkManagementService.Stub
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDnsIfaceForPid(String iface, int pid) throws IllegalStateException {
|
||||
mContext.enforceCallingOrSelfPermission(CONNECTIVITY_INTERNAL, TAG);
|
||||
try {
|
||||
String cmd = "resolver setifaceforpid " + iface + " " + pid;
|
||||
|
||||
mConnector.execute(cmd);
|
||||
} catch (NativeDaemonConnectorException e) {
|
||||
throw new IllegalStateException(
|
||||
"Error communicating with native deamon to set interface for pid" + iface, e);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void clearDnsIfaceForPid(int pid) throws IllegalStateException {
|
||||
mContext.enforceCallingOrSelfPermission(CONNECTIVITY_INTERNAL, TAG);
|
||||
try {
|
||||
String cmd = "resolver clearifaceforpid " + pid;
|
||||
|
||||
mConnector.execute(cmd);
|
||||
} catch (NativeDaemonConnectorException e) {
|
||||
throw new IllegalStateException(
|
||||
"Error communicating with native deamon to clear interface for pid " + pid, e);
|
||||
}
|
||||
}
|
||||
|
||||
/** {@inheritDoc} */
|
||||
public void monitor() {
|
||||
if (mConnector != null) {
|
||||
mConnector.monitor();
|
||||
|
||||
Reference in New Issue
Block a user