fixed zstdmt corruption issue when enabling overlapped sections

see Asana board for detailed explanation on why and how to fix it
This commit is contained in:
Yann Collet
2017-01-25 16:25:38 -08:00
parent 943cff9c37
commit bb0027405a
6 changed files with 46 additions and 18 deletions
+1
View File
@@ -238,6 +238,7 @@ void ZSTDMT_compressChunk(void* jobDescription)
} else {
size_t const initError = ZSTD_compressBegin_advanced(job->cctx, job->srcStart, job->dictSize, job->params, job->fullFrameSize);
if (ZSTD_isError(initError)) { job->cSize = initError; goto _endJob; }
ZSTD_setCCtxParameter(job->cctx, ZSTD_p_forceWindow, 1);
}
if (!job->firstChunk) { /* flush frame header */
size_t const hSize = ZSTD_compressContinue(job->cctx, dstBuff.start, dstBuff.size, src, 0);