summaryrefslogtreecommitdiffstats
path: root/applypatch
diff options
context:
space:
mode:
authorKelvin Zhang <zhangkelvin@google.com>2020-09-17 02:19:41 +0200
committerGerrit Code Review <noreply-gerritcodereview@google.com>2020-09-17 02:19:41 +0200
commita35202befd6460a30330d57e7e69564bc6fb29f9 (patch)
tree8a910b26d07884180bcef5f5f48781ae642cf99e /applypatch
parentMerge "Merge Android R" (diff)
parentSwitch to zip64 in recovery (diff)
downloadandroid_bootable_recovery-a35202befd6460a30330d57e7e69564bc6fb29f9.tar
android_bootable_recovery-a35202befd6460a30330d57e7e69564bc6fb29f9.tar.gz
android_bootable_recovery-a35202befd6460a30330d57e7e69564bc6fb29f9.tar.bz2
android_bootable_recovery-a35202befd6460a30330d57e7e69564bc6fb29f9.tar.lz
android_bootable_recovery-a35202befd6460a30330d57e7e69564bc6fb29f9.tar.xz
android_bootable_recovery-a35202befd6460a30330d57e7e69564bc6fb29f9.tar.zst
android_bootable_recovery-a35202befd6460a30330d57e7e69564bc6fb29f9.zip
Diffstat (limited to 'applypatch')
-rw-r--r--applypatch/imgdiff.cpp6
-rw-r--r--applypatch/include/applypatch/imgdiff_image.h3
2 files changed, 5 insertions, 4 deletions
diff --git a/applypatch/imgdiff.cpp b/applypatch/imgdiff.cpp
index 85860281a..d0cb687cb 100644
--- a/applypatch/imgdiff.cpp
+++ b/applypatch/imgdiff.cpp
@@ -682,9 +682,9 @@ bool ZipModeImage::InitializeChunks(const std::string& filename, ZipArchiveHandl
}
// Create a list of deflated zip entries, sorted by offset.
- std::vector<std::pair<std::string, ZipEntry>> temp_entries;
+ std::vector<std::pair<std::string, ZipEntry64>> temp_entries;
std::string name;
- ZipEntry entry;
+ ZipEntry64 entry;
while ((ret = Next(cookie, &entry, &name)) == 0) {
if (entry.method == kCompressDeflated || limit_ > 0) {
temp_entries.emplace_back(name, entry);
@@ -757,7 +757,7 @@ bool ZipModeImage::InitializeChunks(const std::string& filename, ZipArchiveHandl
}
bool ZipModeImage::AddZipEntryToChunks(ZipArchiveHandle handle, const std::string& entry_name,
- ZipEntry* entry) {
+ ZipEntry64* entry) {
size_t compressed_len = entry->compressed_length;
if (compressed_len == 0) return true;
diff --git a/applypatch/include/applypatch/imgdiff_image.h b/applypatch/include/applypatch/imgdiff_image.h
index aa8d129c3..b579e56ae 100644
--- a/applypatch/include/applypatch/imgdiff_image.h
+++ b/applypatch/include/applypatch/imgdiff_image.h
@@ -257,7 +257,8 @@ class ZipModeImage : public Image {
// Initialize image chunks based on the zip entries.
bool InitializeChunks(const std::string& filename, ZipArchiveHandle handle);
// Add the a zip entry to the list.
- bool AddZipEntryToChunks(ZipArchiveHandle handle, const std::string& entry_name, ZipEntry* entry);
+ bool AddZipEntryToChunks(ZipArchiveHandle handle, const std::string& entry_name,
+ ZipEntry64* entry);
// Return the real size of the zip file. (omit the trailing zeros that used for alignment)
bool GetZipFileSize(size_t* input_file_size);