linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] nfs: use 'break' instead of 'fallthrough'
@ 2020-09-24 10:58 Sudip Mukherjee
  0 siblings, 0 replies; only message in thread
From: Sudip Mukherjee @ 2020-09-24 10:58 UTC (permalink / raw)
  To: Trond Myklebust, Anna Schumaker; +Cc: linux-kernel, linux-nfs, Sudip Mukherjee

The fallthrough attribute should only be used in a switch statement,
after a preceding statement and before a logically succeeding case
label, or user-defined label.

But here, it is used in the last 'switch-case' with no other 'case' where
it can fallthrough. So, use break instead of fallthrough.

Fixes: cf65e49f89f2 ("nfs: Convert to use the preferred fallthrough macro")
Signed-off-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
---
 fs/nfs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/nfs/super.c b/fs/nfs/super.c
index d20326ee0475..eb2401079b04 100644
--- a/fs/nfs/super.c
+++ b/fs/nfs/super.c
@@ -889,7 +889,7 @@ static struct nfs_server *nfs_try_mount_request(struct fs_context *fc)
 		default:
 			if (rpcauth_get_gssinfo(flavor, &info) != 0)
 				continue;
-			fallthrough;
+			break;
 		}
 		dfprintk(MOUNT, "NFS: attempting to use auth flavor %u\n", flavor);
 		ctx->selected_flavor = flavor;
-- 
2.11.0


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2020-09-24 11:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-09-24 10:58 [PATCH] nfs: use 'break' instead of 'fallthrough' Sudip Mukherjee

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).