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

Btrfs: fix the inode ref searches done by btrfs_search_path_in_tree



This is used by the inode lookup ioctl to follow all the backrefs up
to the subvol root.  But the search being done would sometimes land one
past the last item in the leaf instead of finding the backref.

This changes the search to look for the highest possible backref and hop
back one item.  It also fixes a leaked path on failure to find the root.

Signed-off-by: default avatarChris Mason <chris.mason@oracle.com>
parent 1b53ac4d
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