am 7f623d6b: am 9506e84b: am c7726147: am 1fce89d9: am de4e7b49: Merge "Include the interface for clearDnsInterfaceForUidRange" into klp-dev
* commit '7f623d6b9459bc982c49f0a74aa2c9911f8e1dd8': Include the interface for clearDnsInterfaceForUidRange
This commit is contained in:
@@ -419,7 +419,7 @@ interface INetworkManagementService
|
|||||||
/**
|
/**
|
||||||
* Clear a user range from being associated with an interface.
|
* Clear a user range from being associated with an interface.
|
||||||
*/
|
*/
|
||||||
void clearDnsInterfaceForUidRange(int uid_start, int uid_end);
|
void clearDnsInterfaceForUidRange(String iface, int uid_start, int uid_end);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Clear the mappings from pid to Dns interface and from uid range to Dns interface.
|
* Clear the mappings from pid to Dns interface and from uid range to Dns interface.
|
||||||
|
|||||||
@@ -3889,7 +3889,7 @@ public class ConnectivityService extends IConnectivityManager.Stub {
|
|||||||
boolean forwardDns) {
|
boolean forwardDns) {
|
||||||
try {
|
try {
|
||||||
mNetd.clearUidRangeRoute(interfaze, uidStart, uidEnd);
|
mNetd.clearUidRangeRoute(interfaze, uidStart, uidEnd);
|
||||||
if (forwardDns) mNetd.clearDnsInterfaceForUidRange(uidStart, uidEnd);
|
if (forwardDns) mNetd.clearDnsInterfaceForUidRange(interfaze, uidStart, uidEnd);
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1686,10 +1686,10 @@ public class NetworkManagementService extends INetworkManagementService.Stub
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void clearDnsInterfaceForUidRange(int uid_start, int uid_end) {
|
public void clearDnsInterfaceForUidRange(String iface, int uid_start, int uid_end) {
|
||||||
mContext.enforceCallingOrSelfPermission(CONNECTIVITY_INTERNAL, TAG);
|
mContext.enforceCallingOrSelfPermission(CONNECTIVITY_INTERNAL, TAG);
|
||||||
try {
|
try {
|
||||||
mConnector.execute("resolver", "clearifaceforuidrange", uid_start, uid_end);
|
mConnector.execute("resolver", "clearifaceforuidrange", iface, uid_start, uid_end);
|
||||||
} catch (NativeDaemonConnectorException e) {
|
} catch (NativeDaemonConnectorException e) {
|
||||||
throw e.rethrowAsParcelableException();
|
throw e.rethrowAsParcelableException();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user