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

Unified Diff: sync/internal_api/syncapi_server_connection_manager.cc

Issue 1553433002: [Sync] Sync should run canary cycle after any network related error (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix android test Created 4 years, 11 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
Index: sync/internal_api/syncapi_server_connection_manager.cc
diff --git a/sync/internal_api/syncapi_server_connection_manager.cc b/sync/internal_api/syncapi_server_connection_manager.cc
index 16646ec7f4df4ee93cbb979c7d8b371b072422e8..a54fcbc8ff6e03791c020e9f9c8e8abe293506b1 100644
--- a/sync/internal_api/syncapi_server_connection_manager.cc
+++ b/sync/internal_api/syncapi_server_connection_manager.cc
@@ -53,9 +53,9 @@ bool SyncAPIBridgedConnection::Init(const char* path,
int error_code = 0;
int response_code = 0;
if (!http->MakeSynchronousPost(&error_code, &response_code)) {
+ DCHECK_NE(error_code, net::OK);
DVLOG(1) << "Http POST failed, error returns: " << error_code;
- response->server_status = HttpResponse::ServerConnectionCodeFromNetError(
- error_code);
+ response->server_status = HttpResponse::CONNECTION_UNAVAILABLE;
return false;
}
« no previous file with comments | « sync/internal_api/syncapi_server_connection_manager.h ('k') | sync/internal_api/syncapi_server_connection_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698