summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTreehugger Robot <treehugger-gerrit@google.com>2020-08-18 05:17:12 +0200
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-08-18 05:17:12 +0200
commitc55e7fd95decbe41ca18f7a4d36df110e7cbd165 (patch)
tree9c61709deac3a727ef109d3734903446d22a0f72
parentMerge changes I0f3f0333,If447b2cf am: 435a5fc0c2 (diff)
parentMerge "Return the correct action for PromptAndWait" (diff)
downloadandroid_bootable_recovery-c55e7fd95decbe41ca18f7a4d36df110e7cbd165.tar
android_bootable_recovery-c55e7fd95decbe41ca18f7a4d36df110e7cbd165.tar.gz
android_bootable_recovery-c55e7fd95decbe41ca18f7a4d36df110e7cbd165.tar.bz2
android_bootable_recovery-c55e7fd95decbe41ca18f7a4d36df110e7cbd165.tar.lz
android_bootable_recovery-c55e7fd95decbe41ca18f7a4d36df110e7cbd165.tar.xz
android_bootable_recovery-c55e7fd95decbe41ca18f7a4d36df110e7cbd165.tar.zst
android_bootable_recovery-c55e7fd95decbe41ca18f7a4d36df110e7cbd165.zip
-rw-r--r--recovery.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/recovery.cpp b/recovery.cpp
index d26424ab1..09738eb85 100644
--- a/recovery.cpp
+++ b/recovery.cpp
@@ -421,15 +421,15 @@ static Device::BuiltinAction PromptAndWait(Device* device, InstallResult status)
case Device::REBOOT:
case Device::SHUTDOWN:
if (!ui->IsTextVisible()) {
- return Device::REBOOT;
+ return chosen_action;
}
// okay to reboot; no need to ask.
if (!update_in_progress) {
- return Device::REBOOT;
+ return chosen_action;
}
// An update might have been failed. Ask if user really wants to reboot.
if (AskToReboot(device, chosen_action)) {
- return Device::REBOOT;
+ return chosen_action;
}
break;