mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
Btrfs: Add leak debugging for extent_buffer and extent_state
This also fixes one leak around the super block when failing to mount the FS. Signed-off-by: Chris Mason <chris.mason@oracle.com>
This commit is contained in:
parent
83041add61
commit
2d2ae54797
3 changed files with 30 additions and 3 deletions
|
@ -915,12 +915,14 @@ fail_tree_root:
|
|||
free_extent_buffer(tree_root->node);
|
||||
fail_sb_buffer:
|
||||
free_extent_buffer(fs_info->sb_buffer);
|
||||
extent_io_tree_empty_lru(&BTRFS_I(fs_info->btree_inode)->io_tree);
|
||||
fail_iput:
|
||||
iput(fs_info->btree_inode);
|
||||
fail:
|
||||
close_all_devices(fs_info);
|
||||
kfree(extent_root);
|
||||
kfree(tree_root);
|
||||
bdi_destroy(&fs_info->bdi);
|
||||
kfree(fs_info);
|
||||
return ERR_PTR(err);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue