aboutsummaryrefslogtreecommitdiffstats
path: root/cmds-subvolume.c
diff options
context:
space:
mode:
authorZhao Lei <zhaolei@cn.fujitsu.com>2015-08-26 22:16:14 +0800
committerDavid Sterba <dsterba@suse.com>2015-08-31 19:25:14 +0200
commit64650e13bba21c325a1ca6ea584a3250e9203b8a (patch)
tree1bdb8f215466f6ceca65da5f1f102caac30edbbd /cmds-subvolume.c
parentbf3639dc625bf5b07a6f30f065fbfa1cfb349869 (diff)
downloadbtrfs-progs-64650e13bba21c325a1ca6ea584a3250e9203b8a.tar.gz
btrfs-progs-64650e13bba21c325a1ca6ea584a3250e9203b8a.tar.xz
btrfs-progs-64650e13bba21c325a1ca6ea584a3250e9203b8a.zip
btrfs-progs: remove code for setup mntid in cmd_subvol_show
We don't need to use value of mntid in cmd_subvol_show(), no need to get its value. Signed-off-by: Zhao Lei <zhaolei@cn.fujitsu.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'cmds-subvolume.c')
-rw-r--r--cmds-subvolume.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/cmds-subvolume.c b/cmds-subvolume.c
index 61f08f5..4258ea1 100644
--- a/cmds-subvolume.c
+++ b/cmds-subvolume.c
@@ -938,7 +938,7 @@ static int cmd_subvol_show(int argc, char **argv)
char uuidparse[BTRFS_UUID_UNPARSED_SIZE];
char *fullpath = NULL, *svpath = NULL, *mnt = NULL;
char raw_prefix[] = "\t\t\t\t";
- u64 sv_id, mntid;
+ u64 sv_id;
int fd = -1, mntfd = -1;
int ret = 1;
DIR *dirstream1 = NULL, *dirstream2 = NULL;
@@ -998,12 +998,6 @@ static int cmd_subvol_show(int argc, char **argv)
goto out;
}
- ret = btrfs_list_get_path_rootid(mntfd, &mntid);
- if (ret) {
- fprintf(stderr, "ERROR: can't get rootid for '%s'\n", mnt);
- goto out;
- }
-
if (sv_id == BTRFS_FS_TREE_OBJECTID) {
printf("%s is btrfs root\n", fullpath);
goto out;