Clean up BpfNetMaps

Cleans up BpfNetMaps.java before enabling mainline code path.

Bug: 202086915
Test: atest FrameworksNetTests
Change-Id: I28e5d63ed4624df540b1ca47b71899cff7321ded
This commit is contained in:
Ken Chen 2022-01-28 10:08:16 +08:00 • committed by Patrick Rohr
commit f5f51339af

View file

@ -10843,7 +10843,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
} else {
mBpfNetMaps.removeNiceApp(uid);
}
} catch (ServiceSpecificException e) {
} catch (RemoteException | ServiceSpecificException e) {
throw new IllegalStateException(e);
}
}
@ -10858,7 +10858,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
} else {
mBpfNetMaps.removeNaughtyApp(uid);
}
} catch (ServiceSpecificException e) {
} catch (RemoteException | ServiceSpecificException e) {
throw new IllegalStateException(e);
}
}
@ -10870,7 +10870,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
try {
mBpfNetMaps.setUidRule(chain, uid,
allow ? INetd.FIREWALL_RULE_ALLOW : INetd.FIREWALL_RULE_DENY);
} catch (ServiceSpecificException e) {
} catch (RemoteException | ServiceSpecificException e) {
throw new IllegalStateException(e);
}
}
@ -10881,7 +10881,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
try {
mBpfNetMaps.setChildChain(chain, enable);
} catch (ServiceSpecificException e) {
} catch (RemoteException | ServiceSpecificException e) {
throw new IllegalStateException(e);
}
}
@ -10908,7 +10908,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
throw new IllegalArgumentException("replaceFirewallChain with invalid chain: "
+ chain);
}
} catch (ServiceSpecificException e) {
} catch (RemoteException | ServiceSpecificException e) {
throw new IllegalStateException(e);
}
}
@ -10918,7 +10918,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
enforceNetworkStackOrSettingsPermission();
try {
mBpfNetMaps.swapActiveStatsMap();
} catch (ServiceSpecificException e) {
} catch (RemoteException | ServiceSpecificException e) {
throw new IllegalStateException(e);
}
}