mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 10:18:25 +00:00
Fix confusion in address checking code.
This was supposed to disallow addresses which are in use by the DHCP server, and the code works fine when only dhcp-range is defined per broadcast domain. It's confused when there are multiple dhcp-ranges which are valid for a particular request.
This commit is contained in:
@@ -696,7 +696,7 @@ struct dhcp_context *address_available(struct dhcp_context *context,
|
|||||||
struct dhcp_context *tmp;
|
struct dhcp_context *tmp;
|
||||||
|
|
||||||
for (tmp = context; tmp; tmp = tmp->current)
|
for (tmp = context; tmp; tmp = tmp->current)
|
||||||
if (taddr.s_addr == context->router.s_addr)
|
if (taddr.s_addr == tmp->router.s_addr)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
for (tmp = context; tmp; tmp = tmp->current)
|
for (tmp = context; tmp; tmp = tmp->current)
|
||||||
|
|||||||
Reference in New Issue
Block a user