summaryrefslogtreecommitdiffstats
path: root/lib/lz4frame.c
diff options
context:
space:
mode:
authorW. Felix Handte <w@felixhandte.com>2018-04-10 17:12:30 (GMT)
committerW. Felix Handte <w@felixhandte.com>2018-04-10 17:26:17 (GMT)
commit59c7d951213bf8593438ae811549655d5a78d2fc (patch)
tree695666fd41e601e488f2bfc214fdd87538a63cf4 /lib/lz4frame.c
parentf88dc900553b3a029e9cd114800016f9364ffc7b (diff)
downloadlz4-59c7d951213bf8593438ae811549655d5a78d2fc.zip
lz4-59c7d951213bf8593438ae811549655d5a78d2fc.tar.gz
lz4-59c7d951213bf8593438ae811549655d5a78d2fc.tar.bz2
Expose a Faster Stream Reset Function
Diffstat (limited to 'lib/lz4frame.c')
-rw-r--r--lib/lz4frame.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/lz4frame.c b/lib/lz4frame.c
index a080fa6..afa5af3 100644
--- a/lib/lz4frame.c
+++ b/lib/lz4frame.c
@@ -532,9 +532,7 @@ static void LZ4F_applyCDict(void* ctx,
if (level < LZ4HC_CLEVEL_MIN) {
LZ4_stream_t_internal* internal_ctx = &((LZ4_stream_t *)ctx)->internal_donotuse;
assert(!internal_ctx->initCheck);
- /* Clear any local dictionary */
- internal_ctx->dictionary = NULL;
- internal_ctx->dictSize = 0;
+ LZ4_resetStream_fast((LZ4_stream_t *)ctx);
/* Point to the dictionary context */
internal_ctx->dictCtx = cdict ? &(cdict->fastCtx->internal_donotuse) : NULL;
} else {