Commit d7407292 authored by Kent Overstreet's avatar Kent Overstreet Committed by Kent Overstreet

bcachefs: Fix faulty assertion

Signed-off-by: default avatarKent Overstreet <kent.overstreet@gmail.com>
parent 2debb1b8
...@@ -661,7 +661,8 @@ static void bch2_btree_path_verify(struct btree_trans *trans, ...@@ -661,7 +661,8 @@ static void bch2_btree_path_verify(struct btree_trans *trans,
for (i = 0; i < (!path->cached ? BTREE_MAX_DEPTH : 1); i++) { for (i = 0; i < (!path->cached ? BTREE_MAX_DEPTH : 1); i++) {
if (!path->l[i].b) { if (!path->l[i].b) {
BUG_ON(c->btree_roots[path->btree_id].b->c.level > i); BUG_ON(!path->cached &&
c->btree_roots[path->btree_id].b->c.level > i);
break; break;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment