aboutsummaryrefslogtreecommitdiff
path: root/lib/lz4hc.c
diff options
context:
space:
mode:
authorYann Collet <cyan@fb.com>2018-05-06 18:26:14 -0700
committerYann Collet <cyan@fb.com>2018-05-06 18:26:14 -0700
commit200b2960d5a5d0fe76d34bb826c236c7c2941563 (patch)
treeb21912c54e910ecdd69c03510eeef8013a00f745 /lib/lz4hc.c
parent24b9c485db34743f83496038d61598d41c3c497e (diff)
downloadlz4-200b2960d5a5d0fe76d34bb826c236c7c2941563.tar.gz
fixed minor conversion warning
Diffstat (limited to 'lib/lz4hc.c')
-rw-r--r--lib/lz4hc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/lz4hc.c b/lib/lz4hc.c
index 059c4b57..b89983fe 100644
--- a/lib/lz4hc.c
+++ b/lib/lz4hc.c
@@ -327,7 +327,8 @@ LZ4HC_InsertAndGetWiderMatch (
if (lookBackLength==0) { /* no back possible */
size_t const maxML = MIN(currentSegmentLength, srcPatternLength);
if ((size_t)longest < maxML) {
- longest = maxML;
+ assert(maxML < 2 GB);
+ longest = (int)maxML;
*matchpos = base + matchIndex; /* virtual pos, relative to ip, to retrieve offset */
*startpos = ip;
}