security/capabilities: remove check for -EINVAL
authorChristian Brauner <christian@brauner.io>
Wed, 22 Aug 2018 11:52:40 +0000 (13:52 +0200)
committerJames Morris <james.morris@microsoft.com>
Wed, 29 Aug 2018 16:05:28 +0000 (09:05 -0700)
bprm_caps_from_vfs_caps() never returned -EINVAL so remove the
rc == -EINVAL check.

Signed-off-by: Christian Brauner <christian@brauner.io>
Reviewed-by: Serge Hallyn <serge@hallyn.com>
Signed-off-by: James Morris <james.morris@microsoft.com>
security/commoncap.c

index f4c33ab..6012f0c 100644 (file)
@@ -684,9 +684,6 @@ static int get_file_caps(struct linux_binprm *bprm, bool *effective, bool *has_f
        }
 
        rc = bprm_caps_from_vfs_caps(&vcaps, bprm, effective, has_fcap);
-       if (rc == -EINVAL)
-               printk(KERN_NOTICE "%s: cap_from_disk returned %d for %s\n",
-                      __func__, rc, bprm->filename);
 
 out:
        if (rc)