Do not run find_lrp_member_ip in find_static_route_outport if the route
has been configured without a valid nexthop. This patch fixes the
following northd warning:
2021-09-18T06:01:37.909Z|00008|ovn_northd|WARN|bad ipv6 address
Fixes: c00852288 ("northd: allow to configure routes with no nexthop")
Reported-by: Jianlin Shi <[email protected]>
Signed-off-by: Lorenzo Bianconi <[email protected]>
---
northd/northd.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/northd/northd.c b/northd/northd.c
index cf2467fe1..884a3a6c1 100644
--- a/northd/northd.c
+++ b/northd/northd.c
@@ -8833,7 +8833,9 @@ find_static_route_outport(struct ovn_datapath *od, struct
hmap *ports,
route->output_port, route->ip_prefix);
return false;
}
- lrp_addr_s = find_lrp_member_ip(out_port, route->nexthop);
+ if (strlen(route->nexthop)) {
+ lrp_addr_s = find_lrp_member_ip(out_port, route->nexthop);
+ }
if (!lrp_addr_s) {
/* There are no IP networks configured on the router's port via
* which 'route->nexthop' is theoretically reachable. But since
@@ -8863,7 +8865,9 @@ find_static_route_outport(struct ovn_datapath *od, struct
hmap *ports,
continue;
}
- lrp_addr_s = find_lrp_member_ip(out_port, route->nexthop);
+ if (strlen(route->nexthop)) {
+ lrp_addr_s = find_lrp_member_ip(out_port, route->nexthop);
+ }
if (lrp_addr_s) {
break;
}
--
2.31.1
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev