]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Ensure we have IPv6 allocated before processing a kernel deleted IPv6 route.
authorRoy Marples <roy@marples.name>
Thu, 9 Oct 2014 10:18:23 +0000 (10:18 +0000)
committerRoy Marples <roy@marples.name>
Thu, 9 Oct 2014 10:18:23 +0000 (10:18 +0000)
ipv6.c

diff --git a/ipv6.c b/ipv6.c
index 3bd0e2cacdd8440b7448a158a86c2015500ff324..daf30d71646e8b44d9edd808ca996d9416a2f12c 100644 (file)
--- a/ipv6.c
+++ b/ipv6.c
@@ -1141,6 +1141,9 @@ ipv6_routedeleted(struct dhcpcd_ctx *ctx, const struct rt6 *rt)
 {
        struct rt6 *f;
 
+       if (ctx->ipv6 == NULL)
+               return 0;
+
        f = find_route6(ctx->ipv6->routes, rt);
        if (f == NULL)
                return 0;