diff options
author | Tom Caputi <[email protected]> | 2017-10-18 13:08:36 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2017-10-18 10:08:36 -0700 |
commit | 35df0bb5565c81ba52de430108b37eced9de0606 (patch) | |
tree | f220b19010b4873dd20035f07d7e6a165c891469 /module | |
parent | ca9b8e8797dbb7109a052bd3d7316ef27081531c (diff) |
Fix ASSERT in dmu_free_long_object_raw()
This small patch fixes an issue where dmu_free_long_object_raw()
calls dnode_hold() after freeing the dnode a line above.
Reviewed-by: Jorgen Lundman <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Tom Caputi <[email protected]>
Closes #6766
Diffstat (limited to 'module')
-rw-r--r-- | module/zfs/dmu.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/module/zfs/dmu.c b/module/zfs/dmu.c index 1aba0b133..42889504f 100644 --- a/module/zfs/dmu.c +++ b/module/zfs/dmu.c @@ -932,9 +932,10 @@ dmu_free_long_object_impl(objset_t *os, uint64_t object, boolean_t raw) dmu_tx_mark_netfree(tx); err = dmu_tx_assign(tx, TXG_WAIT); if (err == 0) { - err = dmu_object_free(os, object, tx); - if (err == 0 && raw) - VERIFY0(dmu_object_dirty_raw(os, object, tx)); + if (raw) + err = dmu_object_dirty_raw(os, object, tx); + if (err == 0) + err = dmu_object_free(os, object, tx); dmu_tx_commit(tx); } else { |