Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 32919
b: refs/heads/master
c: d1bbf14
h: refs/heads/master
i:
  32917: fb6828e
  32915: 7fed566
  32911: e7f2883
v: v3
  • Loading branch information
NeilBrown authored and Linus Torvalds committed Jul 31, 2006
1 parent a72b63f commit b5ce645
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a5ca63cb60892c1703998daf80d2d1b04cb70103
refs/heads/master: d1bbf14f37261c2c0dba71404602e1ddcec069d2
20 changes: 13 additions & 7 deletions trunk/fs/nfsd/nfsfh.c
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,11 @@ fh_verify(struct svc_rqst *rqstp, struct svc_fh *fhp, int type, int access)
goto out;
}

/* Set user creds for this exportpoint */
error = nfserrno(nfsd_setuser(rqstp, exp));
if (error)
goto out;

/*
* Look up the dentry using the NFS file handle.
*/
Expand Down Expand Up @@ -241,16 +246,17 @@ fh_verify(struct svc_rqst *rqstp, struct svc_fh *fhp, int type, int access)
dprintk("nfsd: fh_verify - just checking\n");
dentry = fhp->fh_dentry;
exp = fhp->fh_export;
/* Set user creds for this exportpoint; necessary even
* in the "just checking" case because this may be a
* filehandle that was created by fh_compose, and that
* is about to be used in another nfsv4 compound
* operation */
error = nfserrno(nfsd_setuser(rqstp, exp));
if (error)
goto out;
}
cache_get(&exp->h);

/* Set user creds for this exportpoint; necessary even in the "just
* checking" case because this may be a filehandle that was created by
* fh_compose, and that is about to be used in another nfsv4 compound
* operation */
error = nfserrno(nfsd_setuser(rqstp, exp));
if (error)
goto out;

error = nfsd_mode_check(rqstp, dentry->d_inode->i_mode, type);
if (error)
Expand Down

0 comments on commit b5ce645

Please sign in to comment.