]> git.ipfire.org Git - people/ms/dnsmasq.git/commitdiff
Use correct DHCP context for PXE-proxy server-id.
authorSimon Kelley <simon@thekelleys.org.uk>
Thu, 14 May 2015 20:30:00 +0000 (21:30 +0100)
committerSimon Kelley <simon@thekelleys.org.uk>
Thu, 14 May 2015 20:30:00 +0000 (21:30 +0100)
src/rfc2131.c

index b95f9beadf59bac3c2a22d9e998907cec0832b59..70d1e59530adcb32e19a9686681b7788b4f901da 100644 (file)
@@ -888,10 +888,10 @@ size_t dhcp_reply(struct dhcp_context *context, char *iface_name, int int_index,
                  
                  option_put(mess, end, OPTION_MESSAGE_TYPE, 1, 
                             mess_type == DHCPDISCOVER ? DHCPOFFER : DHCPACK);
-                 option_put(mess, end, OPTION_SERVER_IDENTIFIER, INADDRSZ, htonl(context->local.s_addr));
+                 option_put(mess, end, OPTION_SERVER_IDENTIFIER, INADDRSZ, htonl(tmp->local.s_addr));
                  pxe_misc(mess, end, uuid);
                  prune_vendor_opts(tagif_netid);
-                 do_encap_opts(pxe_opts(pxearch, tagif_netid, context->local, now), OPTION_VENDOR_CLASS_OPT, DHOPT_VENDOR_MATCH, mess, end, 0);
+                 do_encap_opts(pxe_opts(pxearch, tagif_netid, tmp->local, now), OPTION_VENDOR_CLASS_OPT, DHOPT_VENDOR_MATCH, mess, end, 0);
                  
                  log_packet("PXE", NULL, emac, emac_len, iface_name, ignore ? "proxy-ignored" : "proxy", NULL, mess->xid);
                  log_tags(tagif_netid, ntohl(mess->xid));