From: Chuck Ebbert Date: Mon, 15 Feb 2010 23:07:39 +0000 (-0500) Subject: vfs: don't call ima_file_check() unconditionally in nfsd_open() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=aeaa5ccd6421fbf9e7ded0ac67b12ea2b9fcf51e;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git vfs: don't call ima_file_check() unconditionally in nfsd_open() commit 1e41568d7378d1ba8c64ba137b9ddd00b59f893a ("Take ima_path_check() in nfsd past dentry_open() in nfsd_open()") moved this code back to its original location but missed the "else". Signed-off-by: Chuck Ebbert Signed-off-by: Al Viro --- diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c index 97d79eff6b7f..8715d194561a 100644 --- a/fs/nfsd/vfs.c +++ b/fs/nfsd/vfs.c @@ -752,7 +752,8 @@ nfsd_open(struct svc_rqst *rqstp, struct svc_fh *fhp, int type, flags, current_cred()); if (IS_ERR(*filp)) host_err = PTR_ERR(*filp); - host_err = ima_file_check(*filp, access); + else + host_err = ima_file_check(*filp, access); out_nfserr: err = nfserrno(host_err); out: