diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index 9df8e3f1ccabea1daa2e3d4fd93fdb6424fa4555..c6c80093eac00d6ae57a84a220c97f42f0a85c23 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -3389,6 +3389,8 @@ int btrfs_read_chunk_tree(struct btrfs_root *root) key.type = 0; again: ret = btrfs_search_slot(NULL, root, &key, path, 0, 0); + if (ret < 0) + goto error; while (1) { leaf = path->nodes[0]; slot = path->slots[0];