(params ZstdEncoderParams, enc *zstd.Encoder)
| 69 | } |
| 70 | |
| 71 | func releaseEncoder(params ZstdEncoderParams, enc *zstd.Encoder) { |
| 72 | select { |
| 73 | case getZstdEncoderChannel(params) <- enc: |
| 74 | default: |
| 75 | // pool is at capacity; let the encoder be garbage collected. |
| 76 | } |
| 77 | } |
| 78 | |
| 79 | // zstdDecoderKey keys the decoder cache on maxDecodedSize as well as params, |
| 80 | // since the size bound is fixed when the decoder is built and can't be changed |
no test coverage detected