mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
8b7917cd81
See https://tip.golang.org/doc/go1.17#gofmt for more details
20 lines
504 B
Go
20 lines
504 B
Go
//go:build cgo
|
|
// +build cgo
|
|
|
|
package zstd
|
|
|
|
import (
|
|
"github.com/valyala/gozstd"
|
|
)
|
|
|
|
// Decompress appends decompressed src to dst and returns the result.
|
|
func Decompress(dst, src []byte) ([]byte, error) {
|
|
return gozstd.Decompress(dst, src)
|
|
}
|
|
|
|
// CompressLevel appends compressed src to dst and returns the result.
|
|
//
|
|
// The given compressionLevel is used for the compression.
|
|
func CompressLevel(dst, src []byte, compressionLevel int) []byte {
|
|
return gozstd.CompressLevel(dst, src, compressionLevel)
|
|
}
|