From 9c43b70c51ab0f5fca871b97b6999d46f289877d Mon Sep 17 00:00:00 2001 From: Roy Marples Date: Fri, 30 Aug 2019 12:50:00 +0100 Subject: [PATCH] Better fix for prior. --- src/ipv6.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/ipv6.c b/src/ipv6.c index c296679b..419a3db3 100644 --- a/src/ipv6.c +++ b/src/ipv6.c @@ -1231,7 +1231,8 @@ out: * or DHCP6 handlers and the existance of any useable * global address on the interface has changed, * call rt_build to add/remove the default route. */ - if (!(ctx->options & DHCPCD_RTBUILD) && + if (ifp->active && ifp->options->options & DHCPCD_IPV6 && + !(ctx->options & DHCPCD_RTBUILD) && (ipv6_ifanyglobal(ifp) != NULL) != anyglobal) rt_build(ctx, AF_INET6); } @@ -2295,9 +2296,6 @@ inet6_raroutes(rb_tree_t *routes, struct dhcpcd_ctx *ctx) struct ra *rap; const struct ipv6_addr *addr; - if (ctx->ra_routers == NULL) - return 0; - TAILQ_FOREACH(rap, ctx->ra_routers, next) { if (rap->expired) continue; -- 2.47.3