diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2022-09-05 12:43:46 -0600 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2022-09-05 12:43:46 -0600 |
commit | 7fba10e5be51a3fe565a6f69a946ece9f0e59a67 (patch) | |
tree | 91bc89b8d1e5dba3ead0319daeef3181ccc6da4d /lib/btrfsprogs/btrfsinspect/rebuildnodes/s3_reinit.go | |
parent | abdc8394bcb7080f01859cbfe367beecf5aef06f (diff) |
Try to uniformly use containers.Set
Diffstat (limited to 'lib/btrfsprogs/btrfsinspect/rebuildnodes/s3_reinit.go')
-rw-r--r-- | lib/btrfsprogs/btrfsinspect/rebuildnodes/s3_reinit.go | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/btrfsprogs/btrfsinspect/rebuildnodes/s3_reinit.go b/lib/btrfsprogs/btrfsinspect/rebuildnodes/s3_reinit.go index 5655eb6..7b43d28 100644 --- a/lib/btrfsprogs/btrfsinspect/rebuildnodes/s3_reinit.go +++ b/lib/btrfsprogs/btrfsinspect/rebuildnodes/s3_reinit.go @@ -105,10 +105,14 @@ func reInitBrokenNodes(ctx context.Context, fs _FS, badNodes []badNode) (map[btr min, max := spanOfTreePath(fs, path) node := RebuiltNode{ - Errs: containers.Set[string]{badNode.Err: struct{}{}}, - MinKey: min, - MaxKey: max, - InTrees: containers.Set[btrfsprim.ObjID]{path.Node(-1).FromTree: struct{}{}}, + Errs: containers.NewSet[string]( + badNode.Err, + ), + MinKey: min, + MaxKey: max, + InTrees: containers.NewSet[btrfsprim.ObjID]( + path.Node(-1).FromTree, + ), Node: btrfstree.Node{ Size: sb.NodeSize, ChecksumType: sb.ChecksumType, |