mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 18:28:25 +00:00
We don't need to check that a cache record is F_HOST in the
duplicate address code, since we're now searching a temporary hash which holds only F_HOST records.
This commit is contained in:
@@ -670,8 +670,7 @@ static void add_hosts_entry(struct crec *cache, struct all_addr *addr, int addrl
|
|||||||
j = (j*2 +((unsigned char *)addr)[i]) % hashsz;
|
j = (j*2 +((unsigned char *)addr)[i]) % hashsz;
|
||||||
|
|
||||||
for (lookup = rhash[j]; lookup; lookup = lookup->next)
|
for (lookup = rhash[j]; lookup; lookup = lookup->next)
|
||||||
if ((lookup->flags & F_HOSTS) &&
|
if ((lookup->flags & flags & (F_IPV4 | F_IPV6)) &&
|
||||||
(lookup->flags & flags & (F_IPV4 | F_IPV6)) &&
|
|
||||||
memcmp(&lookup->addr.addr, addr, addrlen) == 0)
|
memcmp(&lookup->addr.addr, addr, addrlen) == 0)
|
||||||
{
|
{
|
||||||
flags &= ~F_REVERSE;
|
flags &= ~F_REVERSE;
|
||||||
|
|||||||
Reference in New Issue
Block a user