Commit f315cf5e authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'for-3.11' of git://linux-nfs.org/~bfields/linux

Pull nfsd fix from Bruce Fields:
 "One more nfsd bugfix for 3.11"

* 'for-3.11' of git://linux-nfs.org/~bfields/linux:
  nfsd: nfsd_open: when dentry_open returns an error do not propagate as struct file
parents c271f5bc e4daf1ff
...@@ -830,9 +830,10 @@ nfsd_open(struct svc_rqst *rqstp, struct svc_fh *fhp, umode_t type, ...@@ -830,9 +830,10 @@ nfsd_open(struct svc_rqst *rqstp, struct svc_fh *fhp, umode_t type,
flags = O_WRONLY|O_LARGEFILE; flags = O_WRONLY|O_LARGEFILE;
} }
*filp = dentry_open(&path, flags, current_cred()); *filp = dentry_open(&path, flags, current_cred());
if (IS_ERR(*filp)) if (IS_ERR(*filp)) {
host_err = PTR_ERR(*filp); host_err = PTR_ERR(*filp);
else { *filp = NULL;
} else {
host_err = ima_file_check(*filp, may_flags); host_err = ima_file_check(*filp, may_flags);
if (may_flags & NFSD_MAY_64BIT_COOKIE) if (may_flags & NFSD_MAY_64BIT_COOKIE)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment