]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Pass the correct pointer when checking the Zip64 end-of-central-directory
authorTim Kientzle <kientzle@acm.org>
Sat, 10 Jan 2015 18:03:41 +0000 (10:03 -0800)
committerTim Kientzle <kientzle@acm.org>
Sat, 10 Jan 2015 18:03:41 +0000 (10:03 -0800)
locator.

This fixes a bug introduced in 94bab9f when I reworked the
EOCD scan.

libarchive/archive_read_support_format_zip.c

index 13f1748195abb077f58a29c31fb1d2b9b5461100..e73c174fcae8f6b7c4233584e04c547077944f9d 100644 (file)
@@ -2372,7 +2372,7 @@ archive_read_format_zip_seekable_bid(struct archive_read *a, int best_bid)
                                         * regular EOCD if present. */
                                        if (i >= 20
                                            && memcmp(p + i - 20, "PK\006\007", 4) == 0) {
-                                               read_zip64_eocd(a, zip, p + i);
+                                               read_zip64_eocd(a, zip, p + i - 20);
                                        }
                                        return (ret);
                                }