Btrfs: don't try and free ebs twice in log replay
This work is done by btrfs_free_path() anyway so there's no need for this duplicate work. Thanks, Signed-off-by: Josef Bacik <jbacik@fusionio.com>
This commit is contained in:
@@ -2161,7 +2161,6 @@ static int walk_log_tree(struct btrfs_trans_handle *trans,
|
|||||||
int wret;
|
int wret;
|
||||||
int level;
|
int level;
|
||||||
struct btrfs_path *path;
|
struct btrfs_path *path;
|
||||||
int i;
|
|
||||||
int orig_level;
|
int orig_level;
|
||||||
|
|
||||||
path = btrfs_alloc_path();
|
path = btrfs_alloc_path();
|
||||||
@@ -2218,12 +2217,6 @@ static int walk_log_tree(struct btrfs_trans_handle *trans,
|
|||||||
}
|
}
|
||||||
|
|
||||||
out:
|
out:
|
||||||
for (i = 0; i <= orig_level; i++) {
|
|
||||||
if (path->nodes[i]) {
|
|
||||||
free_extent_buffer(path->nodes[i]);
|
|
||||||
path->nodes[i] = NULL;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
btrfs_free_path(path);
|
btrfs_free_path(path);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user