diff options
author | daichi <daichi@FreeBSD.org> | 2007-10-14 13:47:44 +0000 |
---|---|---|
committer | daichi <daichi@FreeBSD.org> | 2007-10-14 13:47:44 +0000 |
commit | f3fd8ae96cc6ea54734a56aada5cca712888788e (patch) | |
tree | df4064ac4936befe02ffff60df6fbdc0e34cdfed /sys/fs/unionfs | |
parent | a009cf6b3cb242d382411f28b524c2271f3eae0a (diff) | |
download | FreeBSD-src-f3fd8ae96cc6ea54734a56aada5cca712888788e.zip FreeBSD-src-f3fd8ae96cc6ea54734a56aada5cca712888788e.tar.gz |
Fixed vnode unlock/vrele untreated issues whenever errors have
occurred during some treatments.
Submitted by: Masanori Ozawa <ozawa@ongs.co.jp> (unionfs developer)
Reviewed by: jeff, kensmith
Approved by: re (kensmith)
MFC after: 1 week
Diffstat (limited to 'sys/fs/unionfs')
-rw-r--r-- | sys/fs/unionfs/union_vnops.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/fs/unionfs/union_vnops.c b/sys/fs/unionfs/union_vnops.c index cd6663f..b14acbf 100644 --- a/sys/fs/unionfs/union_vnops.c +++ b/sys/fs/unionfs/union_vnops.c @@ -1197,18 +1197,18 @@ unionfs_rename(struct vop_rename_args *ap) vrele(fdvp); if (fvp != rfvp) vrele(fvp); + if (ltdvp != NULLVP) + VOP_UNLOCK(ltdvp, 0, td); if (tdvp != rtdvp) vrele(tdvp); + if (ltvp != NULLVP) + VOP_UNLOCK(ltvp, 0, td); if (tvp != rtvp && tvp != NULLVP) { if (rtvp == NULLVP) vput(tvp); else vrele(tvp); } - if (ltdvp != NULLVP) - VOP_UNLOCK(ltdvp, 0, td); - if (ltvp != NULLVP) - VOP_UNLOCK(ltvp, 0, td); UNIONFS_INTERNAL_DEBUG("unionfs_rename: leave (%d)\n", error); |