From b9d5de0644cdb4a2bb9b2cf064d72ae18bef7c86 Mon Sep 17 00:00:00 2001 From: Mostyn Bramley-Moore Date: Sun, 22 Aug 2021 22:56:50 +0200 Subject: [PATCH] Use snappy.NewBufferedWriter instead of the deprecated NewWriter --- snappy/snappy.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/snappy/snappy.go b/snappy/snappy.go index b756321..c045d84 100644 --- a/snappy/snappy.go +++ b/snappy/snappy.go @@ -51,7 +51,7 @@ type reader struct { func init() { c := &compressor{} c.poolCompressor.New = func() interface{} { - w := snappylib.NewWriter(ioutil.Discard) + w := snappylib.NewBufferedWriter(ioutil.Discard) return &writer{Writer: w, pool: &c.poolCompressor} } encoding.RegisterCompressor(c)