diff options
| author | Suleiman Souhlal <ssouhlal@FreeBSD.org> | 2005-09-02 15:27:23 +0000 |
|---|---|---|
| committer | Suleiman Souhlal <ssouhlal@FreeBSD.org> | 2005-09-02 15:27:23 +0000 |
| commit | 75d7ba93af7d630911ccc1184ad0a93feae22ef1 (patch) | |
| tree | 6d3fd63626ff1d58add99ac395ebda844196e694 /sys/fs/udf/udf_vfsops.c | |
| parent | 02dfd2b299ef9e368a9acad907dc3a5d7ccf32b1 (diff) | |
Notes
Diffstat (limited to 'sys/fs/udf/udf_vfsops.c')
| -rw-r--r-- | sys/fs/udf/udf_vfsops.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/fs/udf/udf_vfsops.c b/sys/fs/udf/udf_vfsops.c index f0db5b2b468a..7292fc14e255 100644 --- a/sys/fs/udf/udf_vfsops.c +++ b/sys/fs/udf/udf_vfsops.c @@ -228,19 +228,18 @@ udf_mount(struct mount *mp, struct thread *td) /* Check that the mount device exists */ if (fspec == NULL) return (EINVAL); - NDINIT(ndp, LOOKUP, FOLLOW, UIO_SYSSPACE, fspec, td); + NDINIT(ndp, LOOKUP, FOLLOW | LOCKLEAF, UIO_SYSSPACE, fspec, td); if ((error = namei(ndp))) return (error); NDFREE(ndp, NDF_ONLY_PNBUF); devvp = ndp->ni_vp; if (vn_isdisk(devvp, &error) == 0) { - vrele(devvp); + vput(devvp); return (error); } /* Check the access rights on the mount device */ - vn_lock(devvp, LK_EXCLUSIVE | LK_RETRY, td); error = VOP_ACCESS(devvp, VREAD, td->td_ucred, td); if (error) error = suser(td); @@ -248,7 +247,6 @@ udf_mount(struct mount *mp, struct thread *td) vput(devvp); return (error); } - VOP_UNLOCK(devvp, 0, td); if ((error = udf_mountfs(devvp, mp, td))) { vrele(devvp); |
