summaryrefslogtreecommitdiff
path: root/lib/btrfs/btrfstree/btree.go
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@lukeshu.com>2023-03-15 15:17:11 -0600
committerLuke Shumaker <lukeshu@lukeshu.com>2023-03-15 15:40:25 -0600
commit56e44b0630448d44f7aa7f85b2098007ddbae06f (patch)
tree2fef6ed9553472c9ff251c27c30ca7dcba16abcc /lib/btrfs/btrfstree/btree.go
parent8387d36fac1f01505b37d90d675609460202310d (diff)
btrfstree: Distinguish between tree-not-found and item-not-found
Diffstat (limited to 'lib/btrfs/btrfstree/btree.go')
-rw-r--r--lib/btrfs/btrfstree/btree.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/btrfs/btrfstree/btree.go b/lib/btrfs/btrfstree/btree.go
index 2fd7c39..7b3721b 100644
--- a/lib/btrfs/btrfstree/btree.go
+++ b/lib/btrfs/btrfstree/btree.go
@@ -45,7 +45,10 @@ type TreeOperator interface {
// If some items are able to be read, but there is an error reading the
// full set, then it might return *both* a list of items and an error.
//
- // If no such item is found, an error that is io/fs.ErrNotExist is
+ // If the tree is not found, an error that is ErrNoTree is
+ // returned.
+ //
+ // If no such item is found, an error that is ErrNoItem is
// returned.
TreeSearchAll(treeID btrfsprim.ObjID, fn func(key btrfsprim.Key, size uint32) int) ([]Item, error) // size is math.MaxUint32 for key-pointers
}