From ab06923576d4a49bc84c94badfcebcb7f6b103a8 Mon Sep 17 00:00:00 2001 From: Erik Kline Date: Mon, 1 Jun 2015 12:44:01 +0900 Subject: Treat RTM_DELNEIGH as a transition to NUD_NONE RTM_DELNEIGHs can happen naturally during garbage collection of STALE entries, as well as when an interface is going down. All other transitions of interest at this time pass through FAILED. Bug: 18581716 Bug: 21531726 Change-Id: Ib2a731dd6ad6ece478df6950d4cc7752588328a4 --- core/java/android/net/IpReachabilityMonitor.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/core/java/android/net/IpReachabilityMonitor.java b/core/java/android/net/IpReachabilityMonitor.java index 78d147d..3cfd8b2 100644 --- a/core/java/android/net/IpReachabilityMonitor.java +++ b/core/java/android/net/IpReachabilityMonitor.java @@ -443,14 +443,13 @@ public class IpReachabilityMonitor { if (mIpWatchList.containsKey(destination)) { final short value = (msgType == NetlinkConstants.RTM_DELNEIGH) - ? StructNdMsg.NUD_FAILED + ? StructNdMsg.NUD_NONE : nudState; mIpWatchList.put(destination, value); } } - if ((msgType == NetlinkConstants.RTM_DELNEIGH) || - (nudState == StructNdMsg.NUD_FAILED)) { + if (nudState == StructNdMsg.NUD_FAILED) { Log.w(TAG, "ALERT: " + eventMsg); handleNeighborLost(eventMsg); } -- cgit v1.1