]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
Fix Cast Warning 1169/head
authorW. Felix Handte <w@felixhandte.com>
Sat, 9 Jun 2018 21:19:04 +0000 (17:19 -0400)
committerW. Felix Handte <w@felixhandte.com>
Wed, 13 Jun 2018 18:58:36 +0000 (14:58 -0400)
lib/compress/zstd_lazy.c

index a63656dade7047fb92f7da742b2d5b416b2ba66e..ca86c3e63020982a4a91801ef5a7ddd39aba809e 100644 (file)
@@ -718,7 +718,7 @@ _storeSequence:
                    && (MEM_read32(repMatch) == MEM_read32(ip)) ) {
                     const BYTE* const repEnd2 = repIndex < prefixLowestIndex ? dictEnd : iend;
                     matchLength = ZSTD_count_2segments(ip+4, repMatch+4, iend, repEnd2, prefixLowest) + 4;
-                    offset = offset_2; offset_2 = offset_1; offset_1 = offset;   /* swap offset_2 <=> offset_1 */
+                    offset = offset_2; offset_2 = offset_1; offset_1 = (U32)offset;   /* swap offset_2 <=> offset_1 */
                     ZSTD_storeSeq(seqStore, 0, anchor, 0, matchLength-MINMATCH);
                     ip += matchLength;
                     anchor = ip;