MCPcopy Create free account
hub / github.com/IBM/sarama / zstdCompress

Function zstdCompress

zstd.go:119–127  ·  view source on GitHub ↗
(params ZstdEncoderParams, dst, src []byte)

Source from the content-addressed store, hash-verified

117}
118
119func zstdCompress(params ZstdEncoderParams, dst, src []byte) ([]byte, error) {
120 enc, err := getZstdEncoder(params)
121 if err != nil {
122 return nil, err
123 }
124 out := enc.EncodeAll(src, dst)
125 releaseEncoder(params, enc)
126 return out, nil
127}

Callers 2

compressFunction · 0.85

Calls 2

getZstdEncoderFunction · 0.85
releaseEncoderFunction · 0.85

Tested by 1