OSDN Git Service

Nat464Xlat: clat management cleanup
authorHugo Benichi <hugobenichi@google.com>
Tue, 27 Jun 2017 06:13:20 +0000 (15:13 +0900)
committerHugo Benichi <hugobenichi@google.com>
Mon, 28 Aug 2017 06:29:23 +0000 (15:29 +0900)
commitb577d65825e623a9868664486482ed137b98b504
tree9c7486f35c24d150a853822af13de49c3e004a9b
parentb5b1308f2fdcf2f3f0b6c862e6afa73017f642f9
Nat464Xlat: clat management cleanup

This patch does some minor refactoring of clat starting/stopping code:
 - remove unused LinkProperties arguments in updateClat
 - remove unused Context argument in Nat464Xlat ctor
 - introduce ensureClatIsStarted and ensureClatIsStopped methods and
   simplify updateClat
 - add clatd to NetworkAgentInfo toString() method
 - clarify some comments

This changes prepare for moving BaseNetworkObserver callbacks to
ConnectivityService.

Bug: 62997041
Bug: 64571917
Test: runtest frameworks-net
      manually connected to IPv6 only network and went to test-ipv6.com
Change-Id: Idb204784614cfe700f73255a7a7b78c5e9ee6eca
services/core/java/com/android/server/ConnectivityService.java
services/core/java/com/android/server/connectivity/Nat464Xlat.java
services/core/java/com/android/server/connectivity/NetworkAgentInfo.java