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

Unified Diff: sync/sessions/sync_session.cc

Issue 10523003: Refactor following sync commit loop change (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Another rebase Created 8 years, 6 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 | « sync/sessions/status_controller_unittest.cc ('k') | sync/sessions/test_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/sessions/sync_session.cc
diff --git a/sync/sessions/sync_session.cc b/sync/sessions/sync_session.cc
index ac874d13077e1ce79d78e8caf8967b6c9a9019f4..36bc2caf67034195e67e0e24a2a6c4c336c3abf9 100644
--- a/sync/sessions/sync_session.cc
+++ b/sync/sessions/sync_session.cc
@@ -235,12 +235,8 @@ bool IsError(SyncerError error) {
bool HadErrors(const ErrorCounters& error) {
const bool download_updates_error =
IsError(error.last_download_updates_result);
- const bool post_commit_error = IsError(error.last_post_commit_result);
- const bool process_commit_response_error =
- IsError(error.last_process_commit_response_result);
- return download_updates_error ||
- post_commit_error ||
- process_commit_response_error;
+ const bool commit_error = IsError(error.commit_result);
+ return download_updates_error || commit_error;
}
} // namespace
@@ -251,9 +247,7 @@ bool SyncSession::Succeeded() const {
bool SyncSession::SuccessfullyReachedServer() const {
const ErrorCounters& error = status_controller_->error();
- bool reached_server = error.last_download_updates_result == SYNCER_OK ||
- error.last_post_commit_result == SYNCER_OK ||
- error.last_process_commit_response_result == SYNCER_OK;
+ bool reached_server = error.last_download_updates_result == SYNCER_OK;
// It's possible that we reached the server on one attempt, then had an error
// on the next (or didn't perform some of the server-communicating commands).
// We want to verify that, for all commands attempted, we successfully spoke
« no previous file with comments | « sync/sessions/status_controller_unittest.cc ('k') | sync/sessions/test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698