]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Fix issue363:Unable to extract large 7z files.
authorMichihiro NAKAJIMA <ggcueroad@gmail.com>
Sun, 3 Aug 2014 04:19:18 +0000 (13:19 +0900)
committerMichihiro NAKAJIMA <ggcueroad@gmail.com>
Sun, 3 Aug 2014 04:19:18 +0000 (13:19 +0900)
Properly changing a variable type up to uint64_t.

libarchive/archive_read_support_format_7zip.c

index c69d873f95300a169ca1913f1ca837f95fce1287..2a4b83da8dcf0f08ab056267d71fb1b19e239b7a 100644 (file)
@@ -1663,7 +1663,7 @@ parse_7zip_uint64(struct archive_read *a, uint64_t *val)
                        mask >>= 1;
                        continue;
                }
-               *val += (avail & (mask -1)) << (8 * i);
+               *val += ((uint64_t)(avail & (mask -1))) << (8 * i);
                break;
        }
        return (0);