diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2023-03-30 15:11:31 -0600 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2023-03-30 15:15:12 -0600 |
commit | e3f0e61282d0190b9744c69ce69dcaeea22e6a3e (patch) | |
tree | 0b3ecf2951baa4745745524d8571f017b8dd85ac /lib/btrfsutil/old_rebuilt_forrest.go | |
parent | beddf8b9e3a45c864bb4b00b7c4fef1e560d59eb (diff) |
btrfs: ReadableFS: Also embed btrfstree.NodeSource
Diffstat (limited to 'lib/btrfsutil/old_rebuilt_forrest.go')
-rw-r--r-- | lib/btrfsutil/old_rebuilt_forrest.go | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/btrfsutil/old_rebuilt_forrest.go b/lib/btrfsutil/old_rebuilt_forrest.go index 91fa275..535aa94 100644 --- a/lib/btrfsutil/old_rebuilt_forrest.go +++ b/lib/btrfsutil/old_rebuilt_forrest.go @@ -461,6 +461,16 @@ func (bt *OldRebuiltForrest) Superblock() (*btrfstree.Superblock, error) { return bt.inner.Superblock() } +// AcquireNode implements btrfstree.NodeSource (and btrfs.ReadableFS). +func (bt *OldRebuiltForrest) AcquireNode(ctx context.Context, addr btrfsvol.LogicalAddr, exp btrfstree.NodeExpectations) (*btrfstree.Node, error) { + return bt.inner.AcquireNode(ctx, addr, exp) +} + +// ReleaseNode implements btrfstree.NodeSource (and btrfs.ReadableFS). +func (bt *OldRebuiltForrest) ReleaseNode(node *btrfstree.Node) { + bt.inner.ReleaseNode(node) +} + // ReadAt implements diskio.ReaderAt[btrfsvol.LogicalAddr] (and btrfs.ReadableFS). func (bt *OldRebuiltForrest) ReadAt(p []byte, off btrfsvol.LogicalAddr) (int, error) { return bt.inner.ReadAt(p, off) |