Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
blk-mq: fix double-free in error path
If the allocation of bt->bs fails, then bt->map can be freed twice, once in blk_mq_init_bitmap_tags() -> bt_alloc(), and once in blk_mq_init_bitmap_tags() -> bt_free(). Fix by setting the pointer to NULL after the first free. Cc: <[email protected]> Signed-off-by: Tony Battersby <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
- Loading branch information