summaryrefslogtreecommitdiff
path: root/server/RouteController.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'server/RouteController.cpp')
-rw-r--r--server/RouteController.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/server/RouteController.cpp b/server/RouteController.cpp
index 4cb145b2..56e3c286 100644
--- a/server/RouteController.cpp
+++ b/server/RouteController.cpp
@@ -815,11 +815,8 @@ WARN_UNUSED_RESULT int modifyRoute(uint16_t action, const char* interface, const
}
int ret = modifyIpRoute(action, table, interface, destination, nexthop);
- // We allow apps to call requestRouteToHost() multiple times with the same route, so ignore
- // EEXIST failures when adding routes to legacy tables.
- if (ret && !(action == RTM_NEWROUTE && ret == -EEXIST &&
- (tableType == RouteController::LEGACY_NETWORK ||
- tableType == RouteController::LEGACY_SYSTEM))) {
+ // Trying to add a route that already exists shouldn't cause an error.
+ if (ret && !(action == RTM_NEWROUTE && ret == -EEXIST)) {
return ret;
}