On Thu, Aug 18, 2016 at 03:30:06PM -0400, Josef Bacik wrote:
> We need to call free_extent_map() on the em we look up.Btrfs: fix em leak in
> find_first_block_group
> 
> We need to call free_extent_map() on the em we look up.

Thanks for fixing it.

Reviewed-by: Liu Bo <bo.li....@oracle.com>

Thanks,

-liubo

> 
> Signed-off-by: Josef Bacik <jba...@fb.com>
> ---
>  fs/btrfs/extent-tree.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
> index 61b494e..20f9fa6 100644
> --- a/fs/btrfs/extent-tree.c
> +++ b/fs/btrfs/extent-tree.c
> @@ -9906,6 +9906,7 @@ static int find_first_block_group(struct btrfs_root 
> *root,
>                       } else {
>                               ret = 0;
>                       }
> +                     free_extent_map(em);
>                       goto out;
>               }
>               path->slots[0]++;
> -- 
> 1.8.3.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to