summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGustavo A. R. Silva <gustavoars@kernel.org>2020-11-20 21:32:20 +0300
committerDavid Howells <dhowells@redhat.com>2021-01-21 19:16:08 +0300
commit634c21bb9867e06221ee1527c5e157e01cd7712c (patch)
tree28b6919ddfaa2376a96024635a62a7c8745bf088
parent19c329f6808995b142b3966301f217c831e7cf31 (diff)
downloadlinux-634c21bb9867e06221ee1527c5e157e01cd7712c.tar.xz
security: keys: Fix fall-through warnings for Clang
In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning by explicitly adding a break statement instead of letting the code fall through to the next case. Link: https://github.com/KSPP/linux/issues/115 Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org> Signed-off-by: David Howells <dhowells@redhat.com> Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org> Reviewed-by: Ben Boeckel <mathstuf@gmail.com>
-rw-r--r--security/keys/process_keys.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/security/keys/process_keys.c b/security/keys/process_keys.c
index 1fe8b934f656..e3d79a7b6db6 100644
--- a/security/keys/process_keys.c
+++ b/security/keys/process_keys.c
@@ -783,6 +783,7 @@ try_again:
if (need_perm != KEY_AUTHTOKEN_OVERRIDE &&
need_perm != KEY_DEFER_PERM_CHECK)
goto invalid_key;
+ break;
case 0:
break;
}