summaryrefslogtreecommitdiff
path: root/cmds-subvolume.c
diff options
context:
space:
mode:
authorWang Shilong <wangsl.fnst@cn.fujitsu.com>2013-07-14 22:32:23 +0800
committerDavid Sterba <dsterba@suse.cz>2013-08-09 14:32:35 +0200
commit936d520a4818c8cc3b969e0065e3242cb8ed0b1b (patch)
tree353872b78395adc60e662ef1424ea26819aa0182 /cmds-subvolume.c
parent610166d0dbc79f739f6178a4291d214c46394181 (diff)
Btrfs-progs: listing subvols and getting default subvol don't need a subv path
Listing subvolumes and getting default subvol in the filesystem don't need a subv path,Any valid path related to Btrfs filesystem is ok to finish the work. Signed-off-by: Wang Shilong <wangsl.fnst@cn.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.cz> Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'cmds-subvolume.c')
-rw-r--r--cmds-subvolume.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/cmds-subvolume.c b/cmds-subvolume.c
index 67ff8a51..16452623 100644
--- a/cmds-subvolume.c
+++ b/cmds-subvolume.c
@@ -424,18 +424,6 @@ static int cmd_subvol_list(int argc, char **argv)
}
subvol = argv[optind];
-
- ret = test_issubvolume(subvol);
- if (ret < 0) {
- fprintf(stderr, "ERROR: error accessing '%s'\n", subvol);
- goto out;
- }
- if (!ret) {
- fprintf(stderr, "ERROR: '%s' is not a subvolume\n", subvol);
- ret = -1;
- goto out;
- }
-
fd = open_file_or_dir(subvol);
if (fd < 0) {
ret = -1;
@@ -662,17 +650,6 @@ static int cmd_subvol_get_default(int argc, char **argv)
usage(cmd_subvol_get_default_usage);
subvol = argv[1];
-
- ret = test_issubvolume(subvol);
- if (ret < 0) {
- fprintf(stderr, "ERROR: error accessing '%s'\n", subvol);
- return 1;
- }
- if (!ret) {
- fprintf(stderr, "ERROR: '%s' is not a subvolume\n", subvol);
- return 1;
- }
-
fd = open_file_or_dir(subvol);
if (fd < 0) {
fprintf(stderr, "ERROR: can't access '%s'\n", subvol);