btrfs-progs: qgroup assign: set path after checking argument count

Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
David Sterba 2015-07-27 16:16:52 +02:00
parent 62ae6b2bf2
commit 79a851f143
1 changed files with 3 additions and 1 deletions

View File

@ -37,7 +37,7 @@ static int qgroup_assign(int assign, int argc, char **argv)
int ret = 0;
int fd;
int e;
char *path = argv[3];
char *path;
struct btrfs_ioctl_qgroup_assign_args args;
DIR *dirstream = NULL;
@ -49,6 +49,8 @@ static int qgroup_assign(int assign, int argc, char **argv)
args.src = parse_qgroupid(argv[1]);
args.dst = parse_qgroupid(argv[2]);
path = argv[3];
/*
* FIXME src should accept subvol path
*/