Skip to content

Commit

Permalink
[Fix] Zstd: Fix compression with the new Zstd API
Browse files Browse the repository at this point in the history
Issue: #4140
  • Loading branch information
vstakhov committed May 8, 2022
1 parent c6a5be1 commit d0d9673
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libserver/cfg_utils.c
Expand Up @@ -2890,7 +2890,7 @@ rspamd_libs_reset_compression (struct rspamd_external_libs_ctx *ctx)
/* Dictionary will be reused automatically if specified */
r = ZSTD_CCtx_reset (ctx->out_zstream, ZSTD_reset_session_only);
if (!ZSTD_isError (r)) {
r = ZSTD_CCtx_setPledgedSrcSize (ctx->out_zstream, 0);
r = ZSTD_CCtx_setPledgedSrcSize (ctx->out_zstream, ZSTD_CONTENTSIZE_UNKNOWN);
}

if (ZSTD_isError (r)) {
Expand Down

0 comments on commit d0d9673

Please sign in to comment.