mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 18:28:25 +00:00
rfc3315: fix incorrect logical '&&' warning
rfc3315.c:1711:28: warning: use of logical '&&' with constant operand [-Wconstant-logical-operand]
if (!(addr_list->flags && ADDRLIST_DECLINED) ||
^ ~~~~~~~~~~~~~~~~~
It's a flag bit so should be bitwise '&' operator
Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
This commit is contained in:
committed by
Simon Kelley
parent
70c50efd0d
commit
b594e8defa
@@ -1708,7 +1708,7 @@ static int config_valid(struct dhcp_config *config, struct dhcp_context *context
|
||||
return 0;
|
||||
|
||||
for (addr_list = config->addr6; addr_list; addr_list = addr_list->next)
|
||||
if (!(addr_list->flags && ADDRLIST_DECLINED) ||
|
||||
if (!(addr_list->flags & ADDRLIST_DECLINED) ||
|
||||
difftime(now, addr_list->decline_time) >= (float)DECLINE_BACKOFF)
|
||||
{
|
||||
addrpart = addr6part(&addr_list->addr.addr6);
|
||||
|
||||
Reference in New Issue
Block a user