mirror of
https://github.com/kdave/btrfs-progs
synced 2025-02-19 19:26:51 +00:00
btrfs-progs: only print the parent or ref root for ref mismatches
While debugging some corruption, I got confused because it appeared as if we had an invalid parent set on a extent reference, because of this message: tree backref 67014213632 parent 5 root 5 not found in extent tree But it turns out that parent and the root are a union, and we were just printing it out regardless of the type of backref it was. Fix the error message to be consistent with the other mismatch messages, simply print parent or root, depending on the ref type. Signed-off-by: Josef Bacik <josef@toxicpanda.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
5f7191135f
commit
bc06a75a04
@ -3936,9 +3936,11 @@ static int all_backpointers_checked(struct extent_record *rec, int print_errs)
|
||||
} else {
|
||||
tback = to_tree_backref(back);
|
||||
fprintf(stderr,
|
||||
"tree backref %llu parent %llu root %llu not found in extent tree\n",
|
||||
"tree backref %llu %s %llu not found in extent tree\n",
|
||||
(unsigned long long)rec->start,
|
||||
(unsigned long long)tback->parent,
|
||||
back->full_backref ? "parent" : "root",
|
||||
back->full_backref ?
|
||||
(unsigned long long)tback->parent :
|
||||
(unsigned long long)tback->root);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user