Lines Matching refs:route

160         for (const auto &route : netLinkInfo_.routeList_) {
161 if (route.destination_.address_ != LOCAL_ROUTE_NEXT_HOP &&
162 route.destination_.address_ != LOCAL_ROUTE_IPV6_DESTINATION) {
163 auto family = GetAddrFamily(route.destination_.address_);
165 auto destAddress = route.destination_.address_ + "/" + std::to_string(route.destination_.prefixlen_);
166 NetsysController::GetInstance().NetworkRemoveRoute(LOCAL_NET_ID, route.iface_, destAddress, nextHop);
177 for (const auto &route : netLinkInfo_.routeList_) {
178 auto destAddress = route.destination_.address_ + "/" + std::to_string(route.destination_.prefixlen_);
179 NetsysController::GetInstance().NetworkRemoveRoute(netId_, route.iface_, destAddress,
180 route.gateway_.address_);
313 NETMGR_LOG_W("remove route info of ip address:[%{public}s]",
315 netLinkInfo_.routeList_.remove_if([family](const Route &route) {
322 return route.destination_.type_ == addrFamily;
355 for (const auto &route : netLinkInfo_.routeList_) {
356 if (newNetLinkInfo.HasRoute(route)) {
357 NETMGR_LOG_W("Same route:[%{public}s] ifo, there is not need to be deleted",
358 CommonUtils::ToAnonymousIp(route.destination_.address_).c_str());
361 std::string destAddress = route.destination_.address_ + "/" + std::to_string(route.destination_.prefixlen_);
362 auto ret = NetsysController::GetInstance().NetworkRemoveRoute(netId_, route.iface_, destAddress,
363 route.gateway_.address_);
365 if (netSupplierType_ != BEARER_VPN && route.destination_.address_ != LOCAL_ROUTE_NEXT_HOP &&
366 route.destination_.address_ != LOCAL_ROUTE_IPV6_DESTINATION) {
367 auto family = GetAddrFamily(route.destination_.address_);
369 res = NetsysController::GetInstance().NetworkRemoveRoute(LOCAL_NET_ID, route.iface_, destAddress, nextHop);
377 for (const auto &route : newNetLinkInfo.routeList_) {
378 if (netLinkInfo_.HasRoute(route)) {
379 NETMGR_LOG_W("Same route:[%{public}s] ifo, there is no need to add it again",
380 CommonUtils::ToAnonymousIp(route.destination_.address_).c_str());
384 std::string destAddress = route.destination_.address_ + "/" + std::to_string(route.destination_.prefixlen_);
386 NetsysController::GetInstance().NetworkAddRoute(netId_, route.iface_, destAddress, route.gateway_.address_);
388 if (netSupplierType_ != BEARER_VPN && route.destination_.address_ != LOCAL_ROUTE_NEXT_HOP &&
389 route.destination_.address_ != LOCAL_ROUTE_IPV6_DESTINATION) {
390 auto family = GetAddrFamily(route.destination_.address_);
392 res = NetsysController::GetInstance().NetworkAddRoute(LOCAL_NET_ID, route.iface_, destAddress, nextHop);