Certain error contitions cause msdosfs_rename() to decrement the

vnode reference count on 'fdvp' more times than it should.

PR:		17347
Submitted by:	Ian Dowse <iedowse@maths.tcd.ie>
Approved by:	bde
This commit is contained in:
dwmalone 2000-07-14 11:52:56 +00:00
parent b436e36344
commit 729fe7fb1f
2 changed files with 4 additions and 4 deletions

View File

@ -1093,7 +1093,6 @@ msdosfs_rename(ap)
VOP_UNLOCK(fvp, 0, p);
if (VTODE(fdvp)->de_StartCluster != VTODE(tdvp)->de_StartCluster)
newparent = 1;
vrele(fdvp);
if (doingdirectory && newparent) {
if (error) /* write access check above */
goto bad;
@ -1161,7 +1160,8 @@ msdosfs_rename(ap)
panic("msdosfs_rename: lost from startdir");
if (!newparent)
VOP_UNLOCK(tdvp, 0, p);
(void) relookup(fdvp, &fvp, fcnp);
if (relookup(fdvp, &fvp, fcnp) == 0)
vrele(fdvp);
if (fvp == NULL) {
/*
* From name has disappeared.

View File

@ -1093,7 +1093,6 @@ msdosfs_rename(ap)
VOP_UNLOCK(fvp, 0, p);
if (VTODE(fdvp)->de_StartCluster != VTODE(tdvp)->de_StartCluster)
newparent = 1;
vrele(fdvp);
if (doingdirectory && newparent) {
if (error) /* write access check above */
goto bad;
@ -1161,7 +1160,8 @@ msdosfs_rename(ap)
panic("msdosfs_rename: lost from startdir");
if (!newparent)
VOP_UNLOCK(tdvp, 0, p);
(void) relookup(fdvp, &fvp, fcnp);
if (relookup(fdvp, &fvp, fcnp) == 0)
vrele(fdvp);
if (fvp == NULL) {
/*
* From name has disappeared.