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

Unified Diff: sync/engine/syncer.cc

Issue 1251203002: [Sync] Add ClearServerData support to Sync Scheduler (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Improve comments Created 5 years, 5 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/engine/syncer.cc
diff --git a/sync/engine/syncer.cc b/sync/engine/syncer.cc
index 0b6bed27b0d5bbec52c5a27df28a68086276ce52..5eccd80161cbef286d02a5e7dd10cbb1a512eb5c 100644
--- a/sync/engine/syncer.cc
+++ b/sync/engine/syncer.cc
@@ -12,6 +12,7 @@
#include "base/trace_event/trace_event.h"
#include "build/build_config.h"
#include "sync/engine/apply_control_data_updates.h"
+#include "sync/engine/clear_server_data.h"
#include "sync/engine/commit.h"
#include "sync/engine/commit_processor.h"
#include "sync/engine/conflict_resolver.h"
@@ -222,4 +223,11 @@ bool Syncer::HandleCycleEnd(
}
}
+bool Syncer::PostClearServerData(SyncSession* session) {
+ DCHECK(session);
+ ClearServerData clear_server_data(session->context()->account_name());
+ const SyncerError post_result = clear_server_data.SendRequest(session);
+ return post_result == SYNCER_OK;
+}
+
} // namespace syncer

Powered by Google App Engine
This is Rietveld 408576698