0
0
Fork 0
mirror of https://github.com/schollz/croc.git synced 2025-10-11 13:21:00 +02:00

Merge pull request #103 from nicolashardy/patch-1

Improve compression speed
This commit is contained in:
Zack 2018-10-23 05:30:28 -07:00 committed by GitHub
commit fc38472015
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,7 +9,7 @@ import (
// Compress returns a compressed byte slice.
func Compress(src []byte) []byte {
compressedData := new(bytes.Buffer)
compress(src, compressedData, 9)
compress(src, compressedData, -2)
return compressedData.Bytes()
}