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

Unified Diff: components/sync/driver/glue/sync_backend_host_core.cc

Issue 2751333007: [Sync] Try to fix race conditions in CookieJarMismatch. (Closed)
Patch Set: Created 3 years, 9 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: components/sync/driver/glue/sync_backend_host_core.cc
diff --git a/components/sync/driver/glue/sync_backend_host_core.cc b/components/sync/driver/glue/sync_backend_host_core.cc
index e2f19544a4b56aedb367996c1e4c06022e460c82..4c869565117d2238f9ea7eb8a9327ee5e7548a36 100644
--- a/components/sync/driver/glue/sync_backend_host_core.cc
+++ b/components/sync/driver/glue/sync_backend_host_core.cc
@@ -585,9 +585,15 @@ void SyncBackendHostCore::DoClearServerData(
}
void SyncBackendHostCore::DoOnCookieJarChanged(bool account_mismatch,
- bool empty_jar) {
+ bool empty_jar,
+ const base::Closure& callback) {
DCHECK(thread_checker_.CalledOnValidThread());
sync_manager_->OnCookieJarChanged(account_mismatch, empty_jar);
+ if (!callback.is_null()) {
+ host_.Call(FROM_HERE,
+ &SyncBackendHostImpl::OnCookieJarChangedDoneOnFrontendLoop,
+ callback);
+ }
}
void SyncBackendHostCore::ClearServerDataDone(

Powered by Google App Engine
This is Rietveld 408576698