diff --git a/orchagent/vnetorch.cpp b/orchagent/vnetorch.cpp index bfe15b702e9f..cce836dd783d 100644 --- a/orchagent/vnetorch.cpp +++ b/orchagent/vnetorch.cpp @@ -1074,7 +1074,7 @@ bool VNetBitmapObject::removeTunnelRoute(IpPrefix& ipPrefix) if (tunnelRouteMap_.find(ipPrefix) == tunnelRouteMap_.end()) { SWSS_LOG_WARN("VNET tunnel route %s doesn't exist", ipPrefix.to_string().c_str()); - return false; + return true; } auto tunnelRouteInfo = tunnelRouteMap_.at(ipPrefix); @@ -1273,7 +1273,7 @@ bool VNetBitmapObject::removeRoute(IpPrefix& ipPrefix) if (routeMap_.find(ipPrefix) == routeMap_.end()) { SWSS_LOG_WARN("VNET route %s doesn't exist", ipPrefix.to_string().c_str()); - return false; + return true; } sai_status_t status = sai_bmtor_api->remove_table_bitmap_router_entry(routeMap_.at(ipPrefix).routeTableEntryId); @@ -1838,7 +1838,7 @@ bool VNetRouteOrch::doRouteTask(const string& vnet, IpPrefix& if (!vnet_orch_->isVnetExists(vnet)) { SWSS_LOG_WARN("VNET %s doesn't exist", vnet.c_str()); - return false; + return (op == DEL_COMMAND) ? true : false; } auto *vnet_obj = vnet_orch_->getTypePtr(vnet); @@ -1863,7 +1863,7 @@ bool VNetRouteOrch::doRouteTask(const string& vnet, IpPrefix& if (!vnet_orch_->isVnetExists(vnet)) { SWSS_LOG_WARN("VNET %s doesn't exist", vnet.c_str()); - return false; + return (op == DEL_COMMAND) ? true : false; } auto *vnet_obj = vnet_orch_->getTypePtr(vnet);