summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorW. Felix Handte <w@felixhandte.com>2018-03-06 20:53:22 (GMT)
committerW. Felix Handte <w@felixhandte.com>2018-03-12 18:58:43 (GMT)
commit64bcbf400ea6c955b029f74e1214dcd03b90f934 (patch)
tree5d9fa113db89cf2a185006236ba059ce8f0d034d
parentb78cf67c9624a6a826ceaa2a9d65f5feb1dd0cfd (diff)
downloadlz4-64bcbf400ea6c955b029f74e1214dcd03b90f934.zip
lz4-64bcbf400ea6c955b029f74e1214dcd03b90f934.tar.gz
lz4-64bcbf400ea6c955b029f74e1214dcd03b90f934.tar.bz2
Optimize Dict Check Condition
-rw-r--r--lib/lz4.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/lz4.c b/lib/lz4.c
index d147681..4f98efa 100644
--- a/lib/lz4.c
+++ b/lib/lz4.c
@@ -708,7 +708,7 @@ _next_match:
/* Encode MatchLength */
{ unsigned matchCode;
- if ((dictDirective==usingExtDict || dictDirective==usingExtDictCtx) && (dictionary != NULL) && (lowLimit==dictLowLimit)) {
+ if ((dictDirective==usingExtDict || dictDirective==usingExtDictCtx) && ((lowLimit==dictLowLimit) & (dictionary != NULL))) {
const BYTE* limit;
match += refDelta;
limit = ip + (dictEnd-match);