mirror of
https://github.com/kdave/btrfs-progs
synced 2025-01-15 18:20:58 +00:00
btrfs-progs: fix stray error message in check
Commit e578b59bf6
("btrfs-progs: convert strerror to implicit %m")
missed adding braces after a conditional so we will see the following
message whenever a tree block needs repair, regardless of whether repair
was successful: "Failed to repair btree: Success"
Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
aca8193adb
commit
8bda5132d8
@ -3473,9 +3473,10 @@ skip_walking:
|
||||
printf("Try to repair the btree for root %llu\n",
|
||||
root->root_key.objectid);
|
||||
ret = repair_btree(root, &corrupt_blocks);
|
||||
if (ret < 0)
|
||||
if (ret < 0) {
|
||||
errno = -ret;
|
||||
fprintf(stderr, "Failed to repair btree: %m\n");
|
||||
}
|
||||
if (!ret)
|
||||
printf("Btree for root %llu is fixed\n",
|
||||
root->root_key.objectid);
|
||||
|
Loading…
Reference in New Issue
Block a user