NPMS: Cleaned up UID removal code.
When an UID is removed, NPMS needs to perform 2 tasks: - Removed internal state associated with the UID. - Call NMS to reset the iptables rules associated with the UID. Currently, the UID removal logic is intermingled with code used used during the UID state path, which has 3 drawbacks: - Adds unnecessary comparisons. - Makes the code more complicated. - Is not handling all scenarios (like removing UID from fw_standby). This CL simplifies how these 2 tasks are achieved. Test: m -j32 cts && cts-tradefed run commandAndExit cts -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests Change-Id: I12e9a6777b0d7168751571889fd7bb2d13934745 Fixes: 31377000
Loading
Please register or sign in to comment