btrfs-progs: restore: don't misreport errors from search_dir

The logic around return value has changed in the metadata restore
patches. The return value from btrfs_search_slot may remain non-zero and
is returned. This is incorrectly interpreted as an error.

Signed-off-by: David Sterba <dsterba@suse.cz>
This commit is contained in:
David Sterba 2015-04-29 16:48:04 +02:00
parent 1b7dd327f4
commit 630a917aa1

View File

@ -812,6 +812,8 @@ static int search_dir(struct btrfs_root *root, struct btrfs_key *key,
goto out;
}
ret = 0;
leaf = path->nodes[0];
while (!leaf) {
if (verbose > 1)