mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-05 06:18:45 -04:00
bcachefs: Fix error handling in bch2_fs_recovery()
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
committed by
Kent Overstreet
parent
dc3b63dc33
commit
082f0801e0
@@ -271,11 +271,13 @@ int bch2_fs_recovery(struct bch_fs *c)
|
||||
continue;
|
||||
|
||||
err = "invalid btree root pointer";
|
||||
ret = -1;
|
||||
if (r->error)
|
||||
goto err;
|
||||
|
||||
err = "error reading btree root";
|
||||
if (bch2_btree_root_read(c, i, &r->key, r->level)) {
|
||||
ret = bch2_btree_root_read(c, i, &r->key, r->level);
|
||||
if (ret) {
|
||||
if (i != BTREE_ID_ALLOC)
|
||||
goto err;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user