From: bfields@fieldses.org (J. Bruce Fields)
To: Steve Dickson <steved@redhat.com>
Cc: Linux NFS Mailing list <linux-nfs@vger.kernel.org>
Subject: Re: [PATCH 03/11] atomicio: removed a warning
Date: Thu, 20 Jul 2017 14:24:03 -0400 [thread overview]
Message-ID: <20170720182403.GA19909@fieldses.org> (raw)
In-Reply-To: <20170719205354.10006-4-steved@redhat.com>
On Wed, Jul 19, 2017 at 04:53:46PM -0400, Steve Dickson wrote:
> atomicio.c:43:7: warning: this statement may fall through [-Wimplicit-fallthrough=]
I think this is wrong. For example, if we don't have permission to do
the IO, this causes atomicio() to return 0 instead of -1.
--b.
>
> Signed-off-by: Steve Dickson <steved@redhat.com>
> ---
> support/nfs/atomicio.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/support/nfs/atomicio.c b/support/nfs/atomicio.c
> index 5e760e6..0234072 100644
> --- a/support/nfs/atomicio.c
> +++ b/support/nfs/atomicio.c
> @@ -42,6 +42,7 @@ ssize_t atomicio(ssize_t(*f) (int, void *, size_t), int fd, void *_s, size_t n)
> case -1:
> if (errno == EINTR || errno == EAGAIN)
> continue;
> + break;
> case 0:
> if (pos != 0)
> return pos;
> --
> 2.13.3
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2017-07-20 18:24 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-19 20:53 [PATCH 00/11] Removed a bunch random warnings Steve Dickson
2017-07-19 20:53 ` [PATCH 01/11] rpcdebug.c: remove a warning Steve Dickson
2017-07-19 20:53 ` [PATCH 02/11] present_address: " Steve Dickson
2017-07-20 18:42 ` J. Bruce Fields
2017-07-19 20:53 ` [PATCH 03/11] atomicio: removed " Steve Dickson
2017-07-20 18:24 ` J. Bruce Fields [this message]
2017-07-21 14:45 ` Steve Dickson
2017-07-19 20:53 ` [PATCH 04/11] cache.c: removed a couple warning Steve Dickson
2017-07-19 20:53 ` [PATCH 05/11] nfsd.c: removed a few warnings Steve Dickson
2017-07-20 18:28 ` J. Bruce Fields
2017-07-21 16:20 ` Steve Dickson
2017-07-19 20:53 ` [PATCH 06/11] bldev_read_serial: removed a couple warnings Steve Dickson
2017-07-19 20:53 ` [PATCH 07/11] device-discovery.c: removed a warning Steve Dickson
2017-07-19 20:53 ` [PATCH 08/11] network.c: removed some warnings Steve Dickson
2017-07-20 18:37 ` J. Bruce Fields
2017-07-21 16:29 ` Steve Dickson
2017-07-21 18:30 ` J. Bruce Fields
2017-07-19 20:53 ` [PATCH 09/11] nfsmount: remove a warning Steve Dickson
2017-07-19 20:53 ` [PATCH 10/11] nfs4mount: removed " Steve Dickson
2017-07-19 20:53 ` [PATCH 11/11] nfsdcltrack.c: remove " Steve Dickson
2017-07-20 10:32 ` Jeff Layton
-- strict thread matches above, loose matches on Subject: below --
2017-07-21 16:37 [PATCH 00/11 V2] Removed a bunch random warnings Steve Dickson
2017-07-21 16:37 ` [PATCH 03/11] atomicio: removed a warning Steve Dickson
2017-07-25 20:51 ` J. Bruce Fields
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=20170720182403.GA19909@fieldses.org \
--to=bfields@fieldses.org \
--cc=linux-nfs@vger.kernel.org \
--cc=steved@redhat.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;
as well as URLs for NNTP newsgroup(s).