From e8ca1b86347992d3c92db8e7a25ee77a6280787b Mon Sep 17 00:00:00 2001 From: Tianjie Xu Date: Fri, 13 Mar 2020 14:25:02 -0700 Subject: Consolidate the wait in recovery's reboot After a reboot function call, we should always wait for it to finish without executing other instructions. Bug: 151110322 Test: build Change-Id: I1dda291a0835ff96df7eaf42eba1a38267a3beeb (cherry picked from commit 00c4aba9bf428717fc00e26a03e97401eca76ee8) --- recovery.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'recovery.cpp') diff --git a/recovery.cpp b/recovery.cpp index 0382697ab..7675121d4 100644 --- a/recovery.cpp +++ b/recovery.cpp @@ -781,13 +781,7 @@ Device::BuiltinAction start_recovery(Device* device, const std::vectorPrint("Retry attempt %d\n", retry_count); // Reboot back into recovery to retry the update. - if (!Reboot("recovery")) { - ui->Print("Reboot failed\n"); - } else { - while (true) { - pause(); - } - } + Reboot("recovery"); } // If this is an eng or userdebug build, then automatically // turn the text display on if the script fails so the error -- cgit v1.2.3