mirror of
https://github.com/kdave/btrfs-progs
synced 2025-04-29 14:37:56 +00:00
btrfs-progs: more verbose errors from test_issubvolume
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
7afde59e38
commit
dddc3e08cb
@ -434,7 +434,7 @@ static int cmd_qgroup_limit(int argc, char **argv)
|
|||||||
path = argv[optind + 1];
|
path = argv[optind + 1];
|
||||||
ret = test_issubvolume(path);
|
ret = test_issubvolume(path);
|
||||||
if (ret < 0) {
|
if (ret < 0) {
|
||||||
error("cannot access '%s'", path);
|
error("cannot access '%s': %s", path, strerror(-ret));
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
if (!ret) {
|
if (!ret) {
|
||||||
|
@ -325,7 +325,7 @@ again:
|
|||||||
|
|
||||||
res = test_issubvolume(path);
|
res = test_issubvolume(path);
|
||||||
if (res < 0) {
|
if (res < 0) {
|
||||||
error("cannot access subvolume %s", path);
|
error("cannot access subvolume %s: %s", path, strerror(-res));
|
||||||
ret = 1;
|
ret = 1;
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
@ -680,7 +680,7 @@ static int cmd_subvol_snapshot(int argc, char **argv)
|
|||||||
retval = 1; /* failure */
|
retval = 1; /* failure */
|
||||||
res = test_issubvolume(subvol);
|
res = test_issubvolume(subvol);
|
||||||
if (res < 0) {
|
if (res < 0) {
|
||||||
error("cannot access subvolume %s", subvol);
|
error("cannot access subvolume %s: %s", subvol, strerror(-res));
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
if (!res) {
|
if (!res) {
|
||||||
@ -886,7 +886,7 @@ static int cmd_subvol_find_new(int argc, char **argv)
|
|||||||
|
|
||||||
ret = test_issubvolume(subvol);
|
ret = test_issubvolume(subvol);
|
||||||
if (ret < 0) {
|
if (ret < 0) {
|
||||||
error("cannot access subvolume %s", subvol);
|
error("cannot access subvolume %s: %s", subvol, strerror(-ret));
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
if (!ret) {
|
if (!ret) {
|
||||||
@ -957,7 +957,8 @@ static int cmd_subvol_show(int argc, char **argv)
|
|||||||
|
|
||||||
ret = test_issubvolume(fullpath);
|
ret = test_issubvolume(fullpath);
|
||||||
if (ret < 0) {
|
if (ret < 0) {
|
||||||
error("cannot access subvolume %s", fullpath);
|
error("cannot access subvolume %s: %s", fullpath,
|
||||||
|
strerror(-ret));
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
if (!ret) {
|
if (!ret) {
|
||||||
|
Loading…
Reference in New Issue
Block a user