diff options
author | mm <mm@FreeBSD.org> | 2013-04-03 09:52:30 +0000 |
---|---|---|
committer | mm <mm@FreeBSD.org> | 2013-04-03 09:52:30 +0000 |
commit | cfe5852fae3b2d38b252d16e354fe70c3a218ead (patch) | |
tree | 5866f634068272411e0050b26c2d1180816d4489 /sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c | |
parent | fe05bc19f7752d5f01d725a1089ef0bfeb6fba00 (diff) | |
download | FreeBSD-src-cfe5852fae3b2d38b252d16e354fe70c3a218ead.zip FreeBSD-src-cfe5852fae3b2d38b252d16e354fe70c3a218ead.tar.gz |
Fix possible pool hold leak in dmu_send_impl()
Problem reported to vendor:
https://www.illumos.org/issues/3645
Reported by: Andriy Gapon <avg@FreeBSD.org>
MFC after: 15 days
Diffstat (limited to 'sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c')
-rw-r--r-- | sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c index 58b981c..502f422 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c +++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_send.c @@ -500,14 +500,14 @@ dmu_send_impl(void *tag, dsl_pool_t *dp, dsl_dataset_t *ds, list_insert_head(&ds->ds_sendstreams, dsp); mutex_exit(&ds->ds_sendstream_lock); + dsl_dataset_long_hold(ds, FTAG); + dsl_pool_rele(dp, tag); + if (dump_bytes(dsp, drr, sizeof (dmu_replay_record_t)) != 0) { err = dsp->dsa_err; goto out; } - dsl_dataset_long_hold(ds, FTAG); - dsl_pool_rele(dp, tag); - err = traverse_dataset(ds, fromtxg, TRAVERSE_PRE | TRAVERSE_PREFETCH, backup_cb, dsp); |