aboutsummaryrefslogtreecommitdiffstats
path: root/module/zfs/dnode.c
diff options
context:
space:
mode:
Diffstat (limited to 'module/zfs/dnode.c')
-rw-r--r--module/zfs/dnode.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/module/zfs/dnode.c b/module/zfs/dnode.c
index 0be72e90a..26471fda0 100644
--- a/module/zfs/dnode.c
+++ b/module/zfs/dnode.c
@@ -1987,13 +1987,11 @@ dnode_free_range(dnode_t *dn, uint64_t off, uint64_t len, dmu_tx_t *tx)
if (off == 0 && len >= blksz) {
/*
* Freeing the whole block; fast-track this request.
- * Note that we won't dirty any indirect blocks,
- * which is fine because we will be freeing the entire
- * file and thus all indirect blocks will be freed
- * by free_children().
*/
blkid = 0;
nblks = 1;
+ if (dn->dn_nlevels > 1)
+ dnode_dirty_l1(dn, 0, tx);
goto done;
} else if (off >= blksz) {
/* Freeing past end-of-data */