Make loadedDictEnd an Index, not the Dict Len

This commit is contained in:
W. Felix Handte
2018-05-23 17:53:03 -04:00
parent 7ef85e0618
commit 298d24fa57
3 changed files with 10 additions and 2 deletions
+1 -1
View File
@@ -72,7 +72,7 @@ size_t ZSTD_compressBlock_fast_generic(
const BYTE* const dictEnd = dictMode == ZSTD_dictMatchState ?
dms->window.nextSrc : NULL;
const U32 dictIndexDelta = dictMode == ZSTD_dictMatchState ?
prefixLowestIndex - (U32)(dictEnd - dictBase) :
ms->loadedDictEnd - (U32)(dictEnd - dictBase) :
0;
const U32 dictAndPrefixLength = (U32)(ip - prefixLowest + dictEnd - dictLowest);