mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-20 02:38:32 +00:00
Fix compiler warning.
This commit is contained in:
committed by
Simon Kelley
parent
532066ee2d
commit
99e8891f85
@@ -92,7 +92,10 @@ size_t dhcp_reply(struct dhcp_context *context, char *iface_name, int int_index,
|
|||||||
struct dhcp_netid known_id, iface_id, cpewan_id;
|
struct dhcp_netid known_id, iface_id, cpewan_id;
|
||||||
struct dhcp_opt *o;
|
struct dhcp_opt *o;
|
||||||
unsigned char pxe_uuid[17];
|
unsigned char pxe_uuid[17];
|
||||||
unsigned char *oui = NULL, *serial = NULL, *class = NULL;
|
unsigned char *oui = NULL, *serial = NULL;
|
||||||
|
#ifdef HAVE_SCRIPT
|
||||||
|
unsigned char *class = NULL;
|
||||||
|
#endif
|
||||||
|
|
||||||
subnet_addr.s_addr = override.s_addr = 0;
|
subnet_addr.s_addr = override.s_addr = 0;
|
||||||
|
|
||||||
@@ -156,8 +159,9 @@ size_t dhcp_reply(struct dhcp_context *context, char *iface_name, int int_index,
|
|||||||
unsigned char *y = option_ptr(opt, offset + elen + 5);
|
unsigned char *y = option_ptr(opt, offset + elen + 5);
|
||||||
oui = option_find1(x, y, 1, 1);
|
oui = option_find1(x, y, 1, 1);
|
||||||
serial = option_find1(x, y, 2, 1);
|
serial = option_find1(x, y, 2, 1);
|
||||||
|
#ifdef HAVE_SCRIPT
|
||||||
class = option_find1(x, y, 3, 1);
|
class = option_find1(x, y, 3, 1);
|
||||||
|
#endif
|
||||||
/* If TR069-id is present set the tag "cpewan-id" to facilitate echoing
|
/* If TR069-id is present set the tag "cpewan-id" to facilitate echoing
|
||||||
the gateway id back. Note that the device class is optional */
|
the gateway id back. Note that the device class is optional */
|
||||||
if (oui && serial)
|
if (oui && serial)
|
||||||
|
|||||||
Reference in New Issue
Block a user