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

Unified Diff: omaha_request_action.cc

Issue 3275006: AU: Implement server-dictated poll interval. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/update_engine.git
Patch Set: rebase to head Created 10 years, 4 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.h ('k') | update_attempter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: omaha_request_action.cc
diff --git a/omaha_request_action.cc b/omaha_request_action.cc
index 1c79fb06949e1ab7c623aaae5ea6d4f2fc119de2..c931065713bc13906506f9340c91b918bf384191 100644
--- a/omaha_request_action.cc
+++ b/omaha_request_action.cc
@@ -3,17 +3,19 @@
// found in the LICENSE file.
#include "update_engine/omaha_request_action.h"
+
#include <inttypes.h>
+
#include <sstream>
+#include <base/string_number_conversions.h>
+#include <base/string_util.h>
+#include <base/time.h>
+#include <base/logging.h>
#include <libxml/parser.h>
#include <libxml/xpath.h>
#include <libxml/xpathInternals.h>
-#include "base/string_number_conversions.h"
-#include "base/string_util.h"
-#include "base/time.h"
-#include "base/logging.h"
#include "update_engine/action_pipe.h"
#include "update_engine/omaha_request_params.h"
#include "update_engine/prefs_interface.h"
@@ -377,8 +379,10 @@ void OmahaRequestAction::TransferComplete(HttpFetcher *fetcher,
return;
}
- const string status(XmlGetProperty(updatecheck_node, "status"));
OmahaResponse output_object;
+ base::StringToInt(XmlGetProperty(updatecheck_node, "PollInterval"),
+ &output_object.poll_interval);
+ const string status(XmlGetProperty(updatecheck_node, "status"));
if (status == "noupdate") {
LOG(INFO) << "No update.";
output_object.update_exists = false;
@@ -409,7 +413,6 @@ void OmahaRequestAction::TransferComplete(HttpFetcher *fetcher,
output_object.is_delta =
XmlGetProperty(updatecheck_node, "IsDelta") == "true";
SetOutputObject(output_object);
- return;
}
}; // namespace chromeos_update_engine
« no previous file with comments | « omaha_request_action.h ('k') | update_attempter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698