AU: Minor fixes to get it to do full update on real device
- Link w/ gtest only for unittests.
- filesystem_copier_action: always send install plan on the output pipe
on success, even if no copy was performed.
- omaha_response_handler: properly choose install partition based on
new GPT partition spec.
- More useful logging to match memento_updater (which update URL is
used, dump of the request/response for the update check).
- Fixed a bug where I wasn't bonding the proper actions together in update_attempter.
BUG=None
TEST=attached unittests/did full update on Eee PC
Review URL: http://codereview.chromium.org/2044001
diff --git a/update_check_action.cc b/update_check_action.cc
index 106400b..57e82eb 100644
--- a/update_check_action.cc
+++ b/update_check_action.cc
@@ -107,6 +107,8 @@
http_fetcher_->set_delegate(this);
string request_post(FormatRequest(params_));
http_fetcher_->SetPostData(request_post.data(), request_post.size());
+ LOG(INFO) << "Checking for update at " << params_.update_url;
+ LOG(INFO) << "Request: " << request_post;
http_fetcher_->BeginTransfer(params_.update_url);
}
@@ -190,8 +192,12 @@
void UpdateCheckAction::TransferComplete(HttpFetcher *fetcher,
bool successful) {
ScopedActionCompleter completer(processor_, this);
- if (!successful)
+ LOG(INFO) << "Update check response: " << string(response_buffer_.begin(),
+ response_buffer_.end());
+ if (!successful) {
+ LOG(ERROR) << "Update check network transfer failed.";
return;
+ }
if (!HasOutputPipe()) {
// Just set success to whether or not the http transfer succeeded,
// which must be true at this point in the code.