mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2025-06-25 10:38:00 +03:00
dmu_objset_hold_flags() should call dsl_dataset_rele_flags() on error
This was caught when doing a manual check to see if #17352 needed to be improved to catch mismatches across stack frames of the kind that were first found in #17340. Reviewed-by: George Amanakis <gamanakis@gmail.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <mav@FreeBSD.org> Signed-off-by: Richard Yao <richard@ryao.dev> Closes #17353
This commit is contained in:
parent
f0baaa329a
commit
83fa80a550
@ -765,7 +765,7 @@ dmu_objset_hold_flags(const char *name, boolean_t decrypt, const void *tag,
|
|||||||
|
|
||||||
err = dmu_objset_from_ds(ds, osp);
|
err = dmu_objset_from_ds(ds, osp);
|
||||||
if (err != 0) {
|
if (err != 0) {
|
||||||
dsl_dataset_rele(ds, tag);
|
dsl_dataset_rele_flags(ds, flags, tag);
|
||||||
dsl_pool_rele(dp, tag);
|
dsl_pool_rele(dp, tag);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user