summaryrefslogtreecommitdiffstats
path: root/src/ipv6.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2019-08-30 12:50:00 +0100
committerRoy Marples <roy@marples.name>2019-08-30 12:50:00 +0100
commit9b99ba841c9b481c4f457233ef31ec6ac8eed336 (patch)
tree70bc170819c67cb41b41e4e352521e84525b651f /src/ipv6.c
parent4051d2390fc0827bb0c3cb14209a32341ddb7a81 (diff)
downloaddhcpcd-9b99ba841c9b481c4f457233ef31ec6ac8eed336.tar.xz
Better fix for prior.
Diffstat (limited to 'src/ipv6.c')
-rw-r--r--src/ipv6.c6
1 files 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;