From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Phil Sutter <phil@nwl.cc>, netfilter-devel@vger.kernel.org
Subject: Re: [conntrack-tools PATCH] src: Eliminate warnings with -Wcalloc-transposed-args
Date: Wed, 6 Nov 2024 00:21:21 +0100 [thread overview]
Message-ID: <ZyqocRah5QRXwr19@calendula> (raw)
In-Reply-To: <ZyqnjF-rGIfSCrte@orbyte.nwl.cc>
On Wed, Nov 06, 2024 at 12:17:32AM +0100, Phil Sutter wrote:
> On Wed, Nov 06, 2024 at 12:10:02AM +0100, Pablo Neira Ayuso wrote:
> > On Tue, Nov 05, 2024 at 10:54:50PM +0100, Phil Sutter wrote:
> > > calloc() expects the number of elements in the first parameter, not the
> > > second. Swap them and while at it drop one pointless cast (the function
> > > returns a void pointer anyway).
> >
> > BTW, will you add
> >
> > -Wcalloc-transposed-args
> >
> > to Makefile.am?
>
> The gcc-14.2.1_p20240921 here seems to have this enabled by default. I
> did not pass any special configure or make options.
I was expecting something like this, thanks for confirming.
prev parent reply other threads:[~2024-11-05 23:21 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-05 21:54 [conntrack-tools PATCH] src: Eliminate warnings with -Wcalloc-transposed-args Phil Sutter
2024-11-05 22:01 ` Florian Westphal
2024-11-05 22:55 ` Phil Sutter
2024-11-05 23:10 ` Pablo Neira Ayuso
2024-11-05 23:17 ` Phil Sutter
2024-11-05 23:21 ` Pablo Neira Ayuso [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=ZyqocRah5QRXwr19@calendula \
--to=pablo@netfilter.org \
--cc=netfilter-devel@vger.kernel.org \
--cc=phil@nwl.cc \
/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