summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTreehugger Robot <treehugger-gerrit@google.com>2020-08-18 05:05:47 +0200
committerGerrit Code Review <noreply-gerritcodereview@google.com>2020-08-18 05:05:47 +0200
commit99277fa6afbb416d9428c3931bd1230c9e78cc15 (patch)
tree9c61709deac3a727ef109d3734903446d22a0f72
parentMerge changes I0f3f0333,If447b2cf (diff)
parentReturn the correct action for PromptAndWait (diff)
downloadandroid_bootable_recovery-99277fa6afbb416d9428c3931bd1230c9e78cc15.tar
android_bootable_recovery-99277fa6afbb416d9428c3931bd1230c9e78cc15.tar.gz
android_bootable_recovery-99277fa6afbb416d9428c3931bd1230c9e78cc15.tar.bz2
android_bootable_recovery-99277fa6afbb416d9428c3931bd1230c9e78cc15.tar.lz
android_bootable_recovery-99277fa6afbb416d9428c3931bd1230c9e78cc15.tar.xz
android_bootable_recovery-99277fa6afbb416d9428c3931bd1230c9e78cc15.tar.zst
android_bootable_recovery-99277fa6afbb416d9428c3931bd1230c9e78cc15.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;