AU: Many minor cleanup changes
postinstall: Run postinst twice, once for pre-commit (ie, before we
mark the install partition bootable in the partition table), and
post-commit (for after we do). This behavior is needed for specific
types of firmware update.
download action: flush caches, as we found was necessary in
memento_updater.sh
omaha request prep action: update the names of keys we look for in
lsb-release, also get the AU server url from a file, rather than
hard-code it.
set bootable flag action: GPT support.
also, some misc utility functions.
BUG=None
TEST=attached unittests
Review URL: http://codereview.chromium.org/1881001
diff --git a/main.cc b/main.cc
index a796a98..4725967 100644
--- a/main.cc
+++ b/main.cc
@@ -29,7 +29,9 @@
gboolean SetupInMainLoop(void* arg) {
// TODO(adlr): Tell update_attempter to start working.
// Comment this in for that:
- //UpdateAttempter* update_attempter = reinterpret_cast<UpdateAttempter*>(arg);
+ UpdateAttempter* update_attempter = reinterpret_cast<UpdateAttempter*>(arg);
+ LOG(INFO) << "Starting update!";
+ update_attempter->Update(false);
return FALSE; // Don't call this callback function again
}
@@ -59,7 +61,6 @@
if (request_name_ret != DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER) {
g_warning("Got result code %u from requesting name", request_name_ret);
g_error_free(error);
- exit(1);
LOG(FATAL) << "Got result code " << request_name_ret
<< " from requesting name, but expected "
<< DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER;