Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
btrfs: ensure that file descriptor used with subvol ioctls is a dir
If the subvol/snapshot create/destroy ioctls are passed a regular file with execute permissions set, we'll eventually Oops while trying to do inode->i_op->lookup via lookup_one_len. This patch ensures that the file descriptor refers to a directory. Fixes: cb8e709 (Btrfs: Fix subvolume creation locking rules) Fixes: 76dda93 (Btrfs: add snapshot/subvolume destroy ioctl) Cc: <[email protected]> #v2.6.29+ Signed-off-by: Jeff Mahoney <[email protected]> Signed-off-by: Chris Mason <[email protected]>
- Loading branch information