mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-04 09:59:32 +00:00
Btrfs: fix memory leak in load_free_space_cache()
load_free_space_cache() has forgotten to free path. Signed-off-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com>
This commit is contained in:
parent
859acaf1a2
commit
a7e221e900
1 changed files with 1 additions and 0 deletions
|
@ -777,6 +777,7 @@ int load_free_space_cache(struct btrfs_fs_info *fs_info,
|
||||||
spin_lock(&block_group->lock);
|
spin_lock(&block_group->lock);
|
||||||
if (block_group->disk_cache_state != BTRFS_DC_WRITTEN) {
|
if (block_group->disk_cache_state != BTRFS_DC_WRITTEN) {
|
||||||
spin_unlock(&block_group->lock);
|
spin_unlock(&block_group->lock);
|
||||||
|
btrfs_free_path(path);
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
spin_unlock(&block_group->lock);
|
spin_unlock(&block_group->lock);
|
||||||
|
|
Loading…
Reference in a new issue