]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Only UDP based on current state, not the offer.
authorRoy Marples <roy@marples.name>
Sat, 27 Feb 2010 08:37:00 +0000 (08:37 +0000)
committerRoy Marples <roy@marples.name>
Sat, 27 Feb 2010 08:37:00 +0000 (08:37 +0000)
dhcpcd.c

index 24db6243f8b3d0f88ea7ac3e7ab8e5397070b165..ac077ad2616f99d16ce7db8ec79b02e9d729adaa 100644 (file)
--- a/dhcpcd.c
+++ b/dhcpcd.c
@@ -720,8 +720,8 @@ open_sockets(struct interface *iface)
        }
        if (iface->udp_fd == -1 &&
            iface->addr.s_addr != 0 &&
-           iface->state->offer != NULL &&
-           iface->state->offer->cookie == htonl(MAGIC_COOKIE))
+           iface->state->new != NULL &&
+           iface->state->new->cookie == htonl(MAGIC_COOKIE))
        {
                if (open_udp_socket(iface) == -1 && errno != EADDRINUSE)
                        syslog(LOG_ERR, "%s: open_udp_socket: %m", iface->name);