Skip to content
Commit cdfb080e authored by Chris Mason's avatar Chris Mason
Browse files

Btrfs: fix use after free when close_ctree frees the orphan_rsv



Near the end of close_ctree, we're calling btrfs_free_block_rsv
to free up the orphan rsv.  The problem is this call updates the
space_info, which has already been freed.

This adds a new __ function that directly calls kfree instead of trying
to update the space infos.

Signed-off-by: default avatarChris Mason <clm@fb.com>
parent 1bbc621e
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