Btrfs-progs: bugfix for scrubbing single devices
authorArne Jansen <sensille@gmx.net>
Tue, 29 Nov 2011 07:40:28 +0000 (08:40 +0100)
committerDavid Sterba <dsterba@suse.cz>
Fri, 18 Jan 2013 17:26:27 +0000 (18:26 +0100)
commit133e4520eab88ee11b31afa4cbb012afdb0bbc28
tree022ff582dc2e2a56b3a4d1049140efcead68bd22
parent681813b7972dcdcd2e989389a6ed5e6b7794dd2b
Btrfs-progs: bugfix for scrubbing single devices

Scrub can be invoked to scrub only a single device of a (mounted) filesystem.
The code determines whether the given path is a mountpoint of a filesystem
by issueing a btrfs-specific ioctl to it. Only in case of EINVAL it assumed
it may be a device, all other errnos just caused it fail, but some devices
(correctly) return ENOTTY. This patch adds this to the error check.

Signed-off-by: Arne Jansen <sensille@gmx.net>
cmds-scrub.c