From: Roy Marples Date: Fri, 29 May 2015 13:42:28 +0000 (+0000) Subject: Set the magic cookie on our faked DHCP messages so we correctly get X-Git-Tag: v6.9.1~72 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6c9b3e63202bc883968fc41da2390ade8c8ca44b;p=thirdparty%2Fdhcpcd.git Set the magic cookie on our faked DHCP messages so we correctly get the subnet. Fixes [ea294abc09]. --- diff --git a/dhcp.c b/dhcp.c index 9a6cd27a..5eb7f466 100644 --- a/dhcp.c +++ b/dhcp.c @@ -2160,6 +2160,7 @@ dhcp_message_new(const struct in_addr *addr, const struct in_addr *mask) if (dhcp == NULL) return NULL; dhcp->yiaddr = addr->s_addr; + dhcp->cookie = htonl(MAGIC_COOKIE); p = dhcp->options; if (mask && mask->s_addr != INADDR_ANY) { *p++ = DHO_SUBNETMASK;