diff options
Diffstat (limited to 'lib/btrfsutil')
-rw-r--r-- | lib/btrfsutil/rebuilt_tree.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/btrfsutil/rebuilt_tree.go b/lib/btrfsutil/rebuilt_tree.go index ca5ccf3..e507851 100644 --- a/lib/btrfsutil/rebuilt_tree.go +++ b/lib/btrfsutil/rebuilt_tree.go @@ -81,6 +81,9 @@ type rebuiltPathInfo struct { } type rebuiltNodeIndex struct { + // idToTree contains this tree, and all of its ancestor trees. + idToTree map[btrfsprim.ObjID]*RebuiltTree + // nodeToRoots contains all nodes in the filesystem that pass // .isOwnerOK, whether or not they're in the tree. nodeToRoots map[btrfsvol.LogicalAddr]rebuiltRoots @@ -108,6 +111,7 @@ func (tree *RebuiltTree) uncachedNodeIndex(ctx context.Context) rebuiltNodeIndex } ret := rebuiltNodeIndex{ + idToTree: indexer.idToTree, nodeToRoots: make(map[btrfsvol.LogicalAddr]rebuiltRoots), } for node, roots := range indexer.run(ctx) { |