summaryrefslogtreecommitdiffstats
path: root/core/java/android/net
diff options
context:
space:
mode:
authorSreeram Ramachandran <sreeram@google.com>2014-06-11 15:56:51 -0700
committerRobert Greenwalt <rgreenwalt@google.com>2014-06-11 23:02:59 +0000
commitfb7690d4e18b69c645922f6ad4110498cc52cd0b (patch)
treee2fc7ca5697fcc24db03e8601fec83c501511ccf /core/java/android/net
parent52769be3ea1fd005ea66b7b08888b3009ac0dadf (diff)
downloadframeworks_base-fb7690d4e18b69c645922f6ad4110498cc52cd0b.zip
frameworks_base-fb7690d4e18b69c645922f6ad4110498cc52cd0b.tar.gz
frameworks_base-fb7690d4e18b69c645922f6ad4110498cc52cd0b.tar.bz2
Fix wifi connectivity issues.
http://ag/480881 changed RouteInfo.getDestination() to return an IpPrefix instead of a LinkAddress. This makes the equals() comparison always fail. So, when ConnectivityService.updateRoutes() is given identical routes, instead of realizing that there's no diff, it would consider them different, and thus add and remove the same route. The add would fail, since the route already existed in netd, but the remove would succeed, leaving the system with no routes and thus no connectivity. Bug: 15564210 Change-Id: I2003b0fcb809cc20837dc489c58af37891ca4556
Diffstat (limited to 'core/java/android/net')
-rw-r--r--core/java/android/net/RouteInfo.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/java/android/net/RouteInfo.java b/core/java/android/net/RouteInfo.java
index ad8e4f7..5f5577c 100644
--- a/core/java/android/net/RouteInfo.java
+++ b/core/java/android/net/RouteInfo.java
@@ -309,7 +309,7 @@ public class RouteInfo implements Parcelable {
RouteInfo target = (RouteInfo) obj;
- return Objects.equals(mDestination, target.getDestination()) &&
+ return Objects.equals(mDestination, target.getDestinationLinkAddress()) &&
Objects.equals(mGateway, target.getGateway()) &&
Objects.equals(mInterface, target.getInterface());
}