mirror of
https://github.com/vbatts/tar-split.git
synced 2025-07-26 17:00:28 +00:00
*.go: linting project specific code
the pointer to the pool may be useful, but holding on that until I get benchmarks of memory use to show the benefit. Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
This commit is contained in:
parent
19fa6f3d1e
commit
516158dbfb
4 changed files with 28 additions and 16 deletions
|
@ -71,6 +71,8 @@ func WriteOutputTarStream(fg storage.FileGetter, up storage.Unpacker, w io.Write
|
|||
crcSum = make([]byte, 8)
|
||||
multiWriter = io.MultiWriter(w, crcHash)
|
||||
copyBuffer = byteBufferPool.Get().([]byte)
|
||||
// TODO once we have some benchmark or memory profile then we can experiment with using *bytes.Buffer
|
||||
//nolint:staticcheck // SA6002 not going to do a pointer here
|
||||
defer byteBufferPool.Put(copyBuffer)
|
||||
} else {
|
||||
crcHash.Reset()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue