[Dnsmasq-discuss] dnsmasq-2.81rc2 findings on macos
Simon Kelley
simon at thekelleys.org.uk
Sun Mar 8 15:19:28 GMT 2020
On 06/03/2020 09:52, Kevin 'ldir' Darbyshire-Bryant wrote:
> Hi Simon,
>
> Some findings for you when building on 2.81rc2 on MacOS Catalina. Don’t know how much of this is new as I only tried it as an experiment :-)
>
> This definitely looks wrong :-)
>
> rfc3315.c:1711:28: warning: use of logical '&&' with constant operand [-Wconstant-logical-operand]
> if (!(addr_list->flags && ADDRLIST_DECLINED)
>
>
> $ make
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c cache.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c rfc1035.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c util.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c option.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c forward.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c network.c
> network.c:786:23: warning: unused parameter 'fd' [-Wunused-parameter]
> int tcp_interface(int fd, int af)
> ^
> network.c:786:31: warning: unused parameter 'af' [-Wunused-parameter]
> int tcp_interface(int fd, int af)
> ^
> network.c:1156:54: warning: unused parameter 'intname' [-Wunused-parameter]
> int local_bind(int fd, union mysockaddr *addr, char *intname, unsigned int ifindex, int is_tcp)
> ^
> 3 warnings generated.
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c dnsmasq.c
> dnsmasq.c:1862:9: warning: unused variable 'a' [-Wunused-variable]
> char a;
> ^
> dnsmasq.c:1913:10: warning: unused variable 'a' [-Wunused-variable]
> char a = 0;
> ^
> 2 warnings generated.
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c dhcp.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c lease.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c rfc2131.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c netlink.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c dbus.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c bpf.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c helper.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c tftp.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c log.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c conntrack.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c dhcp6.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c rfc3315.c
> rfc3315.c:1711:28: warning: use of logical '&&' with constant operand [-Wconstant-logical-operand]
> if (!(addr_list->flags && ADDRLIST_DECLINED) ||
> ^ ~~~~~~~~~~~~~~~~~
> rfc3315.c:1711:28: note: use '&' for a bitwise operation
> if (!(addr_list->flags && ADDRLIST_DECLINED) ||
> ^~
> &
> rfc3315.c:1711:28: note: remove constant to silence this warning
> if (!(addr_list->flags && ADDRLIST_DECLINED) ||
> ~^~~~~~~~~~~~~~~~~~~~
> 1 warning generated.
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c dhcp-common.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c outpacket.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c radv.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c slaac.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c auth.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c ipset.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c domain.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c dnssec.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c blockdata.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c tables.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c loop.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c inotify.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c poll.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c rrfilter.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c edns0.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c arp.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c crypto.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c dump.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c ubus.c
> cc -Wall -W -O2 -DVERSION='"2.81rc2"' -c metrics.c
> cc -o dnsmasq cache.o rfc1035.o util.o option.o forward.o network.o dnsmasq.o dhcp.o lease.o rfc2131.o netlink.o dbus.o bpf.o helper.o tftp.o log.o conntrack.o dhcp6.o rfc3315.o dhcp-common.o outpacket.o radv.o slaac.o auth.o ipset.o domain.o dnssec.o blockdata.o tables.o loop.o inotify.o poll.o rrfilter.o edns0.o arp.o crypto.o dump.o ubus.o metrics.o
>
> Cheers,
>
> Kevin D-B
>
> gpg: 012C ACB2 28C6 C53E 9775 9123 B3A2 389B 9DE2 334A
>
>
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>
Yes, the ADDRLOST_DECLINED thing is wrong. There must be a law which
states that probability of stupid errors increases as release time nears
and patches become "small" and "trivial".
Both your patches have been applied.
Cheers,
Simon.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/attachments/20200308/1d8174af/attachment.sig>
More information about the Dnsmasq-discuss
mailing list