From d5801c5fe2c1ad72162259c6f1ba79fdd14128e7 Mon Sep 17 00:00:00 2001 From: Ethan Yonker Date: Mon, 14 Apr 2014 08:59:35 -0500 Subject: Force zip verification in OEM builds Change-Id: Ie894b5f5cda64f83b1bb58bb977024230b0337f2 --- twinstall.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/twinstall.cpp b/twinstall.cpp index 4b055a3aa..d95efed13 100644 --- a/twinstall.cpp +++ b/twinstall.cpp @@ -252,7 +252,7 @@ static int Run_Update_Binary(const char *path, ZipArchive *Zip, int* wipe_cache) } extern "C" int TWinstall_zip(const char* path, int* wipe_cache) { - int ret_val, zip_verify, md5_return, key_count; + int ret_val, zip_verify = 1, md5_return, key_count; twrpDigest md5sum; string strpath = path; ZipArchive Zip; @@ -269,7 +269,9 @@ extern "C" int TWinstall_zip(const char* path, int* wipe_cache) { } else if (md5_return == 0) gui_print("Zip MD5 matched.\n"); // MD5 found and matched. +#ifndef TW_OEM_BUILD DataManager::GetValue(TW_SIGNED_ZIP_VERIFY_VAR, zip_verify); +#endif DataManager::SetProgress(0); if (zip_verify) { gui_print("Verifying zip signature...\n"); -- cgit v1.2.3