Unverified Commit 8ff363ad authored by Christophe JAILLET's avatar Christophe JAILLET Committed by Christian Brauner
Browse files

block: Fix a memory leak in bdev_open_by_dev()

If we early exit here, 'handle' needs to be freed, or some memory leaks.

Fixes: ed5cc702

 ("block: Add config option to not allow writing to mounted devices")
Signed-off-by: default avatarChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Link: https://lore.kernel.org/r/8eaec334781e695810aaa383b55de00ca4ab1352.1703439383.git.christophe.jaillet@wanadoo.fr


Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Reviewed-by: default avatarJens Axboe <axboe@kernel.dk>
Signed-off-by: default avatarChristian Brauner <brauner@kernel.org>
parent 63513f85
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment