Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F152658774
D55539.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
762 B
Referenced Files
None
Subscribers
None
D55539.id.diff
View Options
diff --git a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c
--- a/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c
+++ b/sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vnops_os.c
@@ -5527,15 +5527,24 @@
}
#endif
- if (error == 0)
+ if (error == 0) {
error = zfs_do_rename(fdvp, &fvp, ap->a_fcnp, tdvp, &tvp,
ap->a_tcnp, ap->a_fcnp->cn_cred);
-
- vrele(fdvp);
- vrele(fvp);
- vrele(tdvp);
- if (tvp != NULL)
- vrele(tvp);
+ vrele(fdvp);
+ vrele(fvp);
+ vrele(tdvp);
+ if (tvp != NULL)
+ vrele(tvp);
+ } else {
+ if (tdvp == tvp)
+ vrele(tdvp);
+ else
+ vput(tdvp);
+ if (tvp != NULL)
+ vput(tvp);
+ vrele(fdvp);
+ vrele(fvp);
+ }
return (error);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Apr 17, 8:21 AM (20 h, 8 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29343765
Default Alt Text
D55539.id.diff (762 B)
Attached To
Mode
D55539: Add renameat(2) and AT_RENAME_NOREPLACE flag for it
Attached
Detach File
Event Timeline
Log In to Comment