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

Unified Diff: google_apis/gcm/tools/mcs_probe.cc

Issue 2450383003: [GCM] Reset store on checkin rejection and add checkin state to internals (Closed)
Patch Set: Fix mcs probe Created 4 years, 1 month 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 | « google_apis/gcm/engine/checkin_request_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: google_apis/gcm/tools/mcs_probe.cc
diff --git a/google_apis/gcm/tools/mcs_probe.cc b/google_apis/gcm/tools/mcs_probe.cc
index 0e76f05512f3af183199014cd26ff93ee1b18150..4dbcf312bbbaa28dc4e28532bb40050aeaaa9a34 100644
--- a/google_apis/gcm/tools/mcs_probe.cc
+++ b/google_apis/gcm/tools/mcs_probe.cc
@@ -231,6 +231,7 @@ class MCSProbe {
void UpdateCallback(bool success);
void ErrorCallback();
void OnCheckInCompleted(
+ net::HttpStatusCode response_code,
const checkin_proto::AndroidCheckinResponse& checkin_response);
void StartMCSLogin();
@@ -463,8 +464,10 @@ void MCSProbe::CheckIn() {
}
void MCSProbe::OnCheckInCompleted(
+ net::HttpStatusCode response_code,
const checkin_proto::AndroidCheckinResponse& checkin_response) {
- bool success = checkin_response.has_android_id() &&
+ bool success = response_code == net::HTTP_OK &&
+ checkin_response.has_android_id() &&
checkin_response.android_id() != 0UL &&
checkin_response.has_security_token() &&
checkin_response.security_token() != 0UL;
« no previous file with comments | « google_apis/gcm/engine/checkin_request_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698