summaryrefslogtreecommitdiffstats
path: root/sys/nfsserver
diff options
context:
space:
mode:
Diffstat (limited to 'sys/nfsserver')
-rw-r--r--sys/nfsserver/nfs_serv.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/nfsserver/nfs_serv.c b/sys/nfsserver/nfs_serv.c
index 17aea87..2d79643 100644
--- a/sys/nfsserver/nfs_serv.c
+++ b/sys/nfsserver/nfs_serv.c
@@ -3428,7 +3428,8 @@ again:
* Probe one of the directory entries to see if the filesystem
* supports VGET.
*/
- if (VFS_VGET(vp->v_mount, dp->d_fileno, &nvp) == EOPNOTSUPP) {
+ if (VFS_VGET(vp->v_mount, dp->d_fileno, LK_EXCLUSIVE, &nvp) ==
+ EOPNOTSUPP) {
error = NFSERR_NOTSUPP;
vrele(vp);
vp = NULL;
@@ -3462,7 +3463,8 @@ again:
* For readdir_and_lookup get the vnode using
* the file number.
*/
- if (VFS_VGET(vp->v_mount, dp->d_fileno, &nvp))
+ if (VFS_VGET(vp->v_mount, dp->d_fileno, LK_EXCLUSIVE,
+ &nvp))
goto invalid;
bzero((caddr_t)nfhp, NFSX_V3FH);
nfhp->fh_fsid =
OpenPOWER on IntegriCloud