Add new route.hasGateway() api
Fixes issues brought in by change to isHostRoute. isHostRoute was technically correct, but the callers really wanted hasNextHop behavior. bug:8597268 Change-Id: I360761ccfa98b2ba34642f717a78fa71ec1bae4f
This commit is contained in:
@ -1470,8 +1470,7 @@ public class ConnectivityService extends IConnectivityManager.Stub {
|
||||
loge("Error modifying route - no interface name");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (r.isHostRoute() == false) {
|
||||
if (r.hasGateway()) {
|
||||
RouteInfo bestRoute = RouteInfo.selectBestRoute(lp.getAllRoutes(), r.getGateway());
|
||||
if (bestRoute != null) {
|
||||
if (bestRoute.getGateway().equals(r.getGateway())) {
|
||||
|
Reference in New Issue
Block a user