From: senhuang42 Date: Fri, 30 Apr 2021 23:52:04 +0000 (-0400) Subject: Fix chaintable check to include rowhash in ZSTD_reduceIndex() X-Git-Tag: v1.5.0^2~49^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=61fe571af69c9f9f97e6db82dc07d7e3b993e17c;p=thirdparty%2Fzstd.git Fix chaintable check to include rowhash in ZSTD_reduceIndex() --- diff --git a/lib/compress/zstd_compress.c b/lib/compress/zstd_compress.c index 5f4c98eaa..0c5acba68 100644 --- a/lib/compress/zstd_compress.c +++ b/lib/compress/zstd_compress.c @@ -2303,7 +2303,7 @@ static void ZSTD_reduceIndex (ZSTD_matchState_t* ms, ZSTD_CCtx_params const* par ZSTD_reduceTable(ms->hashTable, hSize, reducerValue); } - if (params->cParams.strategy != ZSTD_fast) { + if (ZSTD_allocateChainTable(params->cParams.strategy, params->useRowMatchFinder, (U32)ms->dedicatedDictSearch)) { U32 const chainSize = (U32)1 << params->cParams.chainLog; if (params->cParams.strategy == ZSTD_btlazy2) ZSTD_reduceTable_btlazy2(ms->chainTable, chainSize, reducerValue);