iproute2/misc
Dario Binacchi 9c9824bcaf arpd: use designated initializers for msghdr structure
This patch fixes the following error:

arpd.c:442:17: error: initialization of 'int' from 'void *' makes integer from pointer without a cast [-Wint-conversion]
  442 |                 NULL,   0,

raised by Buildroot autobuilder [1].

In the case in question, the analysis of socket.h [2] containing the
msghdr structure shows that it has been modified with the addition of
padding fields, which cause the compilation error. The use of designated
initializers allows the issue to be fixed.

struct msghdr {
	void *msg_name;
	socklen_t msg_namelen;
	struct iovec *msg_iov;
	int __pad1;
	int msg_iovlen;
	int __pad1;
	void *msg_control;
	int __pad2;
	socklen_t msg_controllen;
	int __pad2;
	int msg_flags;
};

[1] http://autobuild.buildroot.org/results/e4cdfa38ae9578992f1c0ff5c4edae3cc0836e3c/
[2] iproute2/host/mips64-buildroot-linux-musl/sysroot/usr/include/sys/socket.h

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2024-09-28 09:23:35 -07:00
..
.gitignore make yacc usage POSIX compatible 2020-01-20 09:43:22 -08:00
arpd.c arpd: use designated initializers for msghdr structure 2024-09-28 09:23:35 -07:00
ifstat.c Fix usage of poll.h header 2024-05-23 09:27:55 -07:00
lnstat_util.c misc: use SPDX 2023-01-14 09:00:34 -08:00
lnstat.c lnstat: Fix deref of null in print_json() function 2024-01-08 09:31:51 -08:00
lnstat.h lnstat: use same version as iproute2 2020-08-03 10:02:47 -07:00
Makefile ss: add checks for bc filter support 2020-05-13 14:28:38 +00:00
nstat.c Fix usage of poll.h header 2024-05-23 09:27:55 -07:00
rtacct.c Fix usage of poll.h header 2024-05-23 09:27:55 -07:00
ss_util.h misc: use SPDX 2023-01-14 09:00:34 -08:00
ss.c ss: fix libbpf version check for ENABLE_BPF_SKSTORAGE_SUPPORT 2024-08-15 08:24:41 -07:00
ssfilter_check.c ssfilter: fix clang warning about conversion 2023-10-31 16:05:21 -07:00
ssfilter.h misc: use SPDX 2023-01-14 09:00:34 -08:00
ssfilter.y misc: use SPDX 2023-01-14 09:00:34 -08:00