Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni via buildroot <buildroot@buildroot.org>
To: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Cc: buildroot@buildroot.org, Petr Vorel <petr.vorel@gmail.com>,
	linux-amarula@amarulasolutions.com
Subject: Re: [Buildroot] [PATCH v3 1/2] package/iproute2: fix building error using designated initializers
Date: Sat, 26 Oct 2024 10:47:52 +0200	[thread overview]
Message-ID: <20241026104752.0d70ccd1@windsurf> (raw)
In-Reply-To: <20240923054626.2911036-1-dario.binacchi@amarulasolutions.com>

On Mon, 23 Sep 2024 07:46:25 +0200
Dario Binacchi <dario.binacchi@amarulasolutions.com> wrote:

> 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,
> 
> The analysis of socket.h [1] containing the msghdr structure shows that
> it has been modified with the addition of padding fields, which cause
> the compilation error:
> 
> struct msghdr {
> 	void *msg_name;
> 	socklen_t msg_namelen;
> 	struct iovec *msg_iov;
> #if __LONG_MAX > 0x7fffffff && __BYTE_ORDER == __BIG_ENDIAN
> 	int __pad1;
> #endif
> 	int msg_iovlen;
> #if __LONG_MAX > 0x7fffffff && __BYTE_ORDER == __LITTLE_ENDIAN
> 	int __pad1;
> #endif
> 	void *msg_control;
> #if __LONG_MAX > 0x7fffffff && __BYTE_ORDER == __BIG_ENDIAN
> 	int __pad2;
> #endif
> 	socklen_t msg_controllen;
> #if __LONG_MAX > 0x7fffffff && __BYTE_ORDER == __LITTLE_ENDIAN
> 	int __pad2;
> #endif
> 	int msg_flags;
> };
> 
> The use of designated initializers allows the issue to be fixed.
> 
> [1] iproute2/host/mips64-buildroot-linux-musl/sysroot/usr/include/sys/socket.h
> 
> Fixes:
> - http://autobuild.buildroot.org/results/e4cdfa38ae9578992f1c0ff5c4edae3cc0836e3c
> 
> Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
> ---
> No changes since v1

Series applied, after updating with the comments from Petr.

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

      parent reply	other threads:[~2024-10-26  8:48 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-23  5:46 [Buildroot] [PATCH v3 1/2] package/iproute2: fix building error using designated initializers Dario Binacchi
2024-09-23  5:46 ` [Buildroot] [PATCH v3 2/2] package/iproute2: bump to version 6.11.0 Dario Binacchi
2024-09-23  5:59   ` Baruch Siach via buildroot
2024-10-15 22:19   ` Petr Vorel
2024-10-15 22:12 ` [Buildroot] [PATCH v3 1/2] package/iproute2: fix building error using designated initializers Petr Vorel
2024-10-26  8:47 ` Thomas Petazzoni via buildroot [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241026104752.0d70ccd1@windsurf \
    --to=buildroot@buildroot.org \
    --cc=dario.binacchi@amarulasolutions.com \
    --cc=linux-amarula@amarulasolutions.com \
    --cc=petr.vorel@gmail.com \
    --cc=thomas.petazzoni@bootlin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox