Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Address a few compiler warnings on Haiku. #1172

Merged
merged 1 commit into from Apr 28, 2023

Conversation

infrastation
Copy link
Member

Looks good enough to me, please shout if anything needs improvements.

In gencode.c instead of casting pointer types copy the data to squelch 4
previously known warnings from GCC and Clang.  (Oddly enough, Haiku is
the only OS that unconditionally puts a 32-bit array into the union
inside struct in6_addr, yet the only OS where these warnings appeared.)

In pcap.c add a temporary workaround for ioctl() to squelch two other
Clang warnings:

pcap.c:1619:6: error: missing field 'size' initializer
  [-Werror,-Wmissing-field-initializers]
pcap.c:1638:6: error: missing field 'size' initializer
  [-Werror,-Wmissing-field-initializers]

With these changes GCC builds are now warning-free, so in build.sh set
LIBPCAP_TAINTED for Clang only and update the comment to show the
current remaining warnings.
@infrastation infrastation merged commit 02b98a9 into the-tcpdump-group:master Apr 28, 2023
20 checks passed
@infrastation infrastation deleted the haiku_warnings branch April 28, 2023 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant