summaryrefslogtreecommitdiff
path: root/security/keys
diff options
context:
space:
mode:
authorAlan Cox <alan@linux.intel.com>2012-09-28 15:20:02 +0400
committerDavid Howells <dhowells@redhat.com>2012-09-28 15:20:02 +0400
commit631527703d1aa2f0c5dc2af0d998f4da95c83f0e (patch)
treea2aec36285e598c3f1c34aef166b242859bddb63 /security/keys
parentbf5308344527d015ac9a6d2bda4ad4d40fd7d943 (diff)
downloadlinux-631527703d1aa2f0c5dc2af0d998f4da95c83f0e.tar.xz
keys: Fix unreachable code
We set ret to NULL then test it. Remove the bogus test Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'security/keys')
-rw-r--r--security/keys/process_keys.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/security/keys/process_keys.c b/security/keys/process_keys.c
index 54339cfd6734..178b8c3b130a 100644
--- a/security/keys/process_keys.c
+++ b/security/keys/process_keys.c
@@ -357,8 +357,6 @@ key_ref_t search_my_process_keyrings(struct key_type *type,
switch (PTR_ERR(key_ref)) {
case -EAGAIN: /* no key */
- if (ret)
- break;
case -ENOKEY: /* negative key */
ret = key_ref;
break;