summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorW. Felix Handte <w@felixhandte.com>2018-04-20 23:37:28 (GMT)
committerW. Felix Handte <w@felixhandte.com>2018-04-20 23:37:28 (GMT)
commitfcc99d1f31bf8a913fa91a5455524b4a14b9a03d (patch)
tree7a917e5753b73983926778707f4db68fc73fb3ee /lib
parenta8cb2feffdead7b49a09aad0dc7b13dcff206e5b (diff)
downloadlz4-fcc99d1f31bf8a913fa91a5455524b4a14b9a03d.zip
lz4-fcc99d1f31bf8a913fa91a5455524b4a14b9a03d.tar.gz
lz4-fcc99d1f31bf8a913fa91a5455524b4a14b9a03d.tar.bz2
Simpler loadDict() Reset
Diffstat (limited to 'lib')
-rw-r--r--lib/lz4hc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/lz4hc.c b/lib/lz4hc.c
index b70d03b..23d84f4 100644
--- a/lib/lz4hc.c
+++ b/lib/lz4hc.c
@@ -882,8 +882,8 @@ int LZ4_loadDictHC (LZ4_streamHC_t* LZ4_streamHCPtr, const char* dictionary, int
dictionary += dictSize - 64 KB;
dictSize = 64 KB;
}
+ LZ4_resetStreamHC(LZ4_streamHCPtr, LZ4_streamHCPtr->internal_donotuse.compressionLevel);
LZ4HC_init (ctxPtr, (const BYTE*)dictionary);
- LZ4HC_clearTables (ctxPtr);
ctxPtr->end = (const BYTE*)dictionary + dictSize;
if (dictSize >= 4) LZ4HC_Insert (ctxPtr, ctxPtr->end-3);
return dictSize;