From: Joe Perches <joe@perches.com>
To: Chuck Lever <chuck.lever@oracle.com>
Cc: Trond Myklebust <Trond.Myklebust@netapp.com>,
linux-nfs <linux-nfs@vger.kernel.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH resend] net/sunrpc: Remove uses of NIPQUAD, use %pI4
Date: Mon, 08 Mar 2010 08:14:55 -0800 [thread overview]
Message-ID: <1268064895.1925.18.camel@Joe-Laptop.home> (raw)
In-Reply-To: <4B951BF0.9050403@oracle.com>
On Mon, 2010-03-08 at 10:46 -0500, Chuck Lever wrote:
> Why remove the (void) here, but not in xprtrdma/transport.c? IMO the
> (void) cast should be left in place at all three call sites.
I didn't notice it in xprtrdma/transport.c, otherwise I'd've
removed it there too.
When the result is not used, snprintf is most commonly not
cast at all.
(There's a space and a tab in the brackets of the grep string)
$ grep -rP --include=*.[ch] "^[ ]+snprintf\s*\(" * | wc -l
1301
$ grep -rP --include=*.[ch] "^[ ]+\(\s*void\s*\)\s*snprintf\s*\(" * | wc -l
9
net/sunrpc/ has 7 of those.
I'll get around to submitting patches for all of them.
next prev parent reply other threads:[~2010-03-08 16:14 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-06 6:46 [PATCH resend] net/sunrpc: Remove uses of NIPQUAD, use %pI4 Joe Perches
2010-03-07 23:28 ` David Miller
2010-03-08 13:58 ` Trond Myklebust
2010-03-08 15:46 ` Chuck Lever
2010-03-08 16:14 ` Joe Perches [this message]
2010-03-08 16:38 ` [PATCH] net/sunrpc: Convert (void)snprintf to snprintf Joe Perches
2010-03-08 20:16 ` David Miller
2010-03-08 20:15 ` [PATCH resend] net/sunrpc: Remove uses of NIPQUAD, use %pI4 David Miller
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=1268064895.1925.18.camel@Joe-Laptop.home \
--to=joe@perches.com \
--cc=Trond.Myklebust@netapp.com \
--cc=chuck.lever@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nfs@vger.kernel.org \
/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