twrpinstall: Remove unnecessary CloseArchive() calls

The destructor MemoryPackage::~MemoryPackage() will automatically call CloseArchive(), so there is no need to repeat the operation to prevent Recovery from crashing.

Change-Id: Ife5d5818bc603f8709e998b856a1e97bc365fc87
This commit is contained in:
sekaiacg
2021-12-04 20:01:46 +08:00
parent 82fba90680
commit cdc0319717
2 changed files with 0 additions and 8 deletions
-2
View File
@@ -66,7 +66,6 @@ bool read_metadata_from_package(ZipArchiveHandle zip, std::string* meta_data) {
size);
if (ret != 0) {
printf("Failed to read metadata in update package.\n");
CloseArchive(zip);
return false;
}
return true;
@@ -213,7 +212,6 @@ abupdate_binary_command(const char* path, int retry_count __unused,
binary_entry.uncompressed_length);
if (extract_ret != 0) {
printf("Can't extract %s\n", AB_OTA_PAYLOAD_PROPERTIES);
CloseArchive(Zip);
return false;
}