mirror of
https://github.com/astaxie/beego.git
synced 2024-11-22 20:00:54 +00:00
gzip method support
This commit is contained in:
parent
5a9bff2000
commit
35e34261ab
@ -96,9 +96,11 @@ func (ac acceptEncoder) put(wr resetWriter, level int) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
wr.Reset(nil)
|
wr.Reset(nil)
|
||||||
|
|
||||||
//notice
|
//notice
|
||||||
//compressionLevel==BestCompression DOES NOT MATTER
|
//compressionLevel==BestCompression DOES NOT MATTER
|
||||||
//sync.Pool will not memory leak
|
//sync.Pool will not memory leak
|
||||||
|
|
||||||
switch level {
|
switch level {
|
||||||
case gzipCompressLevel:
|
case gzipCompressLevel:
|
||||||
ac.customCompressLevelPool.Put(wr)
|
ac.customCompressLevelPool.Put(wr)
|
||||||
|
Loading…
Reference in New Issue
Block a user