From 2a56592d589e52928d86729301a367efd0c9817f Mon Sep 17 00:00:00 2001 From: Daniel Zheng Date: Wed, 31 May 2023 11:20:08 -0700 Subject: [PATCH] Reverting code to old flashing code Falling back on old flashing code until fastboot-info is fixed Test: m fastboot, fastboot flashall Change-Id: I10146ec75f75d57d4a4049d35def370533619401 --- fastboot/fastboot.cpp | 24 ++---------------------- 1 file changed, 2 insertions(+), 22 deletions(-) diff --git a/fastboot/fastboot.cpp b/fastboot/fastboot.cpp index 3a135bc46..bec4ef1e9 100644 --- a/fastboot/fastboot.cpp +++ b/fastboot/fastboot.cpp @@ -1784,28 +1784,8 @@ void FlashAllTool::Flash() { CancelSnapshotIfNeeded(); - std::vector contents; - if (!fp_->source->ReadFile("fastboot-info.txt", &contents)) { - LOG(VERBOSE) << "Flashing from hardcoded images. fastboot-info.txt is empty or does not " - "exist"; - HardcodedFlash(); - return; - } - - std::vector> tasks = - ParseFastbootInfo(fp_, Split({contents.data(), contents.size()}, "\n")); - - if (tasks.empty()) { - LOG(FATAL) << "Invalid fastboot-info.txt file."; - } - LOG(VERBOSE) << "Flashing from fastboot-info.txt"; - for (auto& task : tasks) { - task->Run(); - } - if (fp_->wants_wipe) { - // avoid adding duplicate wipe tasks in fastboot main code. - fp_->wants_wipe = false; - } + HardcodedFlash(); + return; } void FlashAllTool::CheckRequirements() {