projects
/
systemd
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b489d6a
)
network: route: handle null address with non-zero prefixlen correctly
author
Yu Watanabe
<watanabe.yu+github@gmail.com>
Sun, 5 Dec 2021 15:29:39 +0000
(
00:29
+0900)
committer
Yu Watanabe
<watanabe.yu+github@gmail.com>
Mon, 6 Dec 2021 10:16:17 +0000
(19:16 +0900)
Previously, even if a link has a route to e.g. ::/96, default gateway
via ::1.2.3.4 cannot be configured.
src/network/networkd-route-util.c
patch
|
blob
|
history
diff --git
a/src/network/networkd-route-util.c
b/src/network/networkd-route-util.c
index c57adbe0ab0a671e3540aa6c070ae34d83c2b082..f5b502f46443e85b65e40ec9eda4e09794d7457f 100644
(file)
--- a/
src/network/networkd-route-util.c
+++ b/
src/network/networkd-route-util.c
@@
-116,7
+116,7
@@
static bool link_address_is_reachable(Link *link, int family, const union in_add
continue;
if (route->family != family)
continue;
- if (!in_addr_is_set(route->family, &route->dst))
+ if (!in_addr_is_set(route->family, &route->dst)
&& route->dst_prefixlen == 0
)
continue;
if (in_addr_prefix_covers(family, &route->dst, route->dst_prefixlen, address) > 0)
return true;