Commit baf269d4 authored by Andrew Steinborn's avatar Andrew Steinborn Committed by Matt Holt

gzip: cleaned up writer pool initialization code (#1695)

parent 20a047f7
......@@ -146,11 +146,7 @@ func initWriterPool() {
// add default writer pool
defaultWriterPoolIndex = i
writerPool[defaultWriterPoolIndex] = &sync.Pool{
New: func() interface{} {
return gzip.NewWriter(ioutil.Discard)
},
}
writerPool[defaultWriterPoolIndex] = newWriterPool(gzip.DefaultCompression)
}
func getWriter(level int) *gzip.Writer {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment