Merge pull request #141 from inikep/dev

fix update for zstd_opt
dev
Yann Collet 2016-03-08 14:41:04 +01:00
commit ff14b351f5
1 changed files with 2 additions and 1 deletions

View File

@ -227,7 +227,6 @@ static U32 ZSTD_insertBtAndGetAllMatches (
const U32 minMatch = (mls == 3) ? 3 : 4;
size_t bestLength = minMatch-1;
hashTable[h] = current; /* Update Hash Table */
if (minMatch == 3) { /* HC3 match finder */
U32 matchIndex3 = ZSTD_insertAndFindFirstIndexHash3 (zc, ip);
@ -256,6 +255,8 @@ static U32 ZSTD_insertBtAndGetAllMatches (
}
}
hashTable[h] = current; /* Update Hash Table */
while (nbCompares-- && (matchIndex > windowLow)) {
U32* nextPtr = bt + 2*(matchIndex & btMask);
size_t matchLength = MIN(commonLengthSmaller, commonLengthLarger); /* guaranteed minimum nb of common bytes */