mirror of
https://github.com/restic/restic.git
synced 2025-12-12 05:11:46 +00:00
archiver: Remove cleanup goroutine from BufferPool
This isn't doing anything. Channels should get cleaned up by the GC when the last reference to them disappears, just like all other data structures. Also inlined BufferPool.Put in Buffer.Release, its only caller.
This commit is contained in:
@@ -76,7 +76,7 @@ func NewFileSaver(ctx context.Context, t *tomb.Tomb, save SaveBlobFn, pol chunke
|
||||
|
||||
s := &FileSaver{
|
||||
saveBlob: save,
|
||||
saveFilePool: NewBufferPool(ctx, int(poolSize), chunker.MaxSize),
|
||||
saveFilePool: NewBufferPool(int(poolSize), chunker.MaxSize),
|
||||
pol: pol,
|
||||
ch: ch,
|
||||
|
||||
|
||||
Reference in New Issue
Block a user