Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(15)

Unified Diff: postinstall_runner_action.cc

Issue 6880077: AU: Handle firmware update failure when booted from FW slot B. (Closed) Base URL: http://git.chromium.org/git/update_engine.git@master
Patch Set: Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « omaha_request_action_unittest.cc ('k') | postinstall_runner_action_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: postinstall_runner_action.cc
diff --git a/postinstall_runner_action.cc b/postinstall_runner_action.cc
index 80c28c955b73793a78e77516eb8fe17f9eb0e254..2c8b943c3c986a6299cfc8657b447cfc92211806 100644
--- a/postinstall_runner_action.cc
+++ b/postinstall_runner_action.cc
@@ -65,6 +65,12 @@ void PostinstallRunnerAction::CompletePostinstall(int return_code) {
ScopedTempUnmounter temp_unmounter(temp_rootfs_dir_);
if (return_code != 0) {
LOG(ERROR) << "Postinst command failed with code: " << return_code;
+ if (return_code == 2) {
+ // This special return code means that we tried to update firmware,
+ // but couldn't because we booted from FW B, and we need to reboot
+ // to get back to FW A.
+ completer.set_code(kActionCodePostinstallBootedFromFirmwareB);
+ }
return;
}
if (HasOutputPipe()) {
« no previous file with comments | « omaha_request_action_unittest.cc ('k') | postinstall_runner_action_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698