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

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: Adjust initial delay for CONNECTION_UNAVAILABLE error. Created 5 years 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..33bfba26fb5b78974a8e8316b4fbcb56c79bf025 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(error_code != net::OK);
Nicolas Zea 2015/12/30 21:34:34 DCHECK_NE?
pavely 2016/01/04 23:31:04 Done.
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