]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Don't assume we always have an IPv4 state.
authorRoy Marples <roy@marples.name>
Thu, 30 May 2013 22:15:23 +0000 (22:15 +0000)
committerRoy Marples <roy@marples.name>
Thu, 30 May 2013 22:15:23 +0000 (22:15 +0000)
ipv4.c

diff --git a/ipv4.c b/ipv4.c
index 3afbb73f198e82c4f8a1c8917f4dbf2aaee01f19..fd2fe955956e55313e312c756d37fe1ab69cd2d2 100644 (file)
--- a/ipv4.c
+++ b/ipv4.c
@@ -650,6 +650,9 @@ ipv4_handleifa(int type, const char *ifname,
                return;
 
        state = D_STATE(ifp);
+       if (state == NULL)
+               return;
+
        if (type == RTM_DELADDR) {
                if (state->new &&
                    state->new->yiaddr == addr->s_addr)