summaryrefslogtreecommitdiff
path: root/src/android/net/util/NetworkStackUtils.java
diff options
context:
space:
mode:
authorRemi NGUYEN VAN <reminv@google.com>2020-06-24 15:54:57 +0900
committerRemi NGUYEN VAN <reminv@google.com>2020-06-24 15:54:57 +0900
commit9890fcdcbf44238e72db587e216e5368a7e2e536 (patch)
treee9a6e7fa4df88f11865aeb566a9a01a488af9a06 /src/android/net/util/NetworkStackUtils.java
parent750fe188d303a7075df1d7df151db2334ddb98c1 (diff)
Get link state with same lock as LinkProperties
The previous IpClientLinkObserver code could in theory call mCallback.update with a linkState that came from another update; for example: 1. onInterfaceAddressUpdated - mLinkProperties.addLinkAddress 2. onInterfaceLinkStateChanged - setInterfaceLinkState(false) 1. mCallback.update(false) <- should be true ? 2. mCallback.update(false) In practice this would not happen because the onFoo methods are all called in order (same binder token from netd), but IpClientLinkObserver should not need to make such assumptions. Bug: 151796056 Test: atest NetworkStackIntegrationTests (see also test-only change) Change-Id: I60f5a319519069070eb5a07643686bf5ec937665
Diffstat (limited to 'src/android/net/util/NetworkStackUtils.java')
0 files changed, 0 insertions, 0 deletions