Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 30925725 authored by Aaron Huang's avatar Aaron Huang
Browse files

Dump mNetworkToIfaces in NetworkPolicyManagerService

Dump last interfaces of the network information in dumpsys of
netpolicy.

Output:
Network to interfaces:
  100: {rmnet_data1}]
  101: {v4-wlan0, wlan0}]

Bug: 237640200
Test: FrameworksNetTests
Change-Id: I258f5565e62666cd71222073c692e45e2e5828e2
parent 6db478c8
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -4049,6 +4049,14 @@ public class NetworkPolicyManagerService extends INetworkPolicyManager.Stub {
                }
                fout.decreaseIndent();

                fout.println("Network to interfaces:");
                fout.increaseIndent();
                for (int i = 0; i < mNetworkToIfaces.size(); ++i) {
                    final int key = mNetworkToIfaces.keyAt(i);
                    fout.println(key + ": " + mNetworkToIfaces.get(key));
                }
                fout.decreaseIndent();

                fout.println();
                mStatLogger.dump(fout);