diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2023-03-23 21:33:19 -0600 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2023-03-23 21:33:19 -0600 |
commit | bf5eed5af5c34b8cf9dc2985a7c4475602929bb1 (patch) | |
tree | 9cb910940a1e16982f5c5012a4fbeb37ba172f82 /lib/btrfsutil/rebuilt_readitem.go | |
parent | f0a9faf21dbe508d57da3b18be9121559c70876a (diff) | |
parent | 418553acc64567ebc95122e28b07657526c92923 (diff) |
Merge branch 'lukeshu/tree-api-pt1-changes'
Diffstat (limited to 'lib/btrfsutil/rebuilt_readitem.go')
-rw-r--r-- | lib/btrfsutil/rebuilt_readitem.go | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/btrfsutil/rebuilt_readitem.go b/lib/btrfsutil/rebuilt_readitem.go index ff919f0..03a7cdc 100644 --- a/lib/btrfsutil/rebuilt_readitem.go +++ b/lib/btrfsutil/rebuilt_readitem.go @@ -42,10 +42,11 @@ func (ts *RebuiltForrest) readNode(ctx context.Context, laddr btrfsvol.LogicalAd LAddr: containers.OptionalValue(laddr), Level: containers.OptionalValue(graphInfo.Level), Generation: containers.OptionalValue(graphInfo.Generation), - Owner: func(treeID btrfsprim.ObjID) error { - if treeID != graphInfo.Owner { - return fmt.Errorf("expected owner=%v but claims to have owner=%v", - graphInfo.Owner, treeID) + Owner: func(treeID btrfsprim.ObjID, gen btrfsprim.Generation) error { + if treeID != graphInfo.Owner || gen != graphInfo.Generation { + return fmt.Errorf("expected owner=%v generation=%v but claims to have owner=%v generation=%v", + graphInfo.Owner, graphInfo.Generation, + treeID, gen) } return nil }, |