mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-07 20:40:21 +01:00
platform: route_search_cache() should not treat a metric 0 as "any" route
This match-any behavior ignoring metric is nowhere used. And even if we
would need such a behavior, using 0 is wrong because IPv4 routes can
have a metric of zero.
(cherry picked from commit 2cb3c7e8a0)
This commit is contained in:
parent
818150bf6e
commit
dd418598d5
1 changed files with 1 additions and 1 deletions
|
|
@ -3865,7 +3865,7 @@ route_search_cache (struct nl_cache *cache, int family, int ifindex, const void
|
|||
if (!_route_match (rtnlroute, family, ifindex, FALSE))
|
||||
continue;
|
||||
|
||||
if (metric && metric != rtnl_route_get_priority (rtnlroute))
|
||||
if (metric != rtnl_route_get_priority (rtnlroute))
|
||||
continue;
|
||||
|
||||
dst = rtnl_route_get_dst (rtnlroute);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue