mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 18:28:25 +00:00
Compare address and interface index for allowed interface
If interface is recreated with the same address but different index, it would not change any other parameter. Test also address family on incoming TCP queries.
This commit is contained in:
committed by
Simon Kelley
parent
51cdd1a227
commit
951a22165c
@@ -1824,7 +1824,8 @@ static void check_dns_listeners(time_t now)
|
||||
addr.addr4 = tcp_addr.in.sin_addr;
|
||||
|
||||
for (iface = daemon->interfaces; iface; iface = iface->next)
|
||||
if (iface->index == if_index)
|
||||
if (iface->index == if_index &&
|
||||
iface->addr.sa.sa_family == tcp_addr.sa.sa_family)
|
||||
break;
|
||||
|
||||
if (!iface && !loopback_exception(listener->tcpfd, tcp_addr.sa.sa_family, &addr, intr_name))
|
||||
|
||||
Reference in New Issue
Block a user