mirror of
https://github.com/restic/restic.git
synced 2026-11-05 14:59:21 +00:00
walker: fix error handling if tree cannot be loaded
A tree that cannot be loaded is a fatal error when walking the tree. Thus, return the error and exit the tree walk.
This commit is contained in:
1 parent
0dffa1208d
commit
10cfe96cd4
2 files changed
+55
-11
No files matched your search
@@ -91,6 +91,8 @@ func walk(ctx context.Context, repo restic.BlobLoader, prefix string, parentTree
|
||||
if err == ErrSkipNode {
|
||||
continue
|
||||
}
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
err = walk(ctx, repo, p, *node.Subtree, subtree, visitor)
|
||||
|
||||
Reference in new issue
Block a user