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

Unified Diff: chrome/browser/sync/glue/sync_backend_host.cc

Issue 8366030: Introduce the plumbing necessary to report Unrecoverable error from model safe workers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: For a high level review. Created 9 years, 2 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: chrome/browser/sync/glue/sync_backend_host.cc
diff --git a/chrome/browser/sync/glue/sync_backend_host.cc b/chrome/browser/sync/glue/sync_backend_host.cc
index ff5374dc4529083c118e3a82e5ec888a1cdccd84..89b4f7120525e8c0fe773c8459b4819825f8da6c 100644
--- a/chrome/browser/sync/glue/sync_backend_host.cc
+++ b/chrome/browser/sync/glue/sync_backend_host.cc
@@ -525,6 +525,18 @@ void SyncBackendHost::Core::OnActionableError(
sync_error));
}
+void SyncBackendHost::Core::OnUnrecoverableError(
+ const tracked_objects::Location& location,
+ const std::string& message) {
+ DCHECK_EQ(MessageLoop::current(), sync_loop_);
+ host_->frontend_loop_->PostTask(
+ FROM_HERE,
+ NewRunnableMethod(this, &Core::HandleUnrecoverableErrorOnFrontendLoop,
+ location,
+ message));
+
+}
+
SyncBackendHost::Core::DoInitializeOptions::DoInitializeOptions(
MessageLoop* sync_loop,
SyncBackendRegistrar* registrar,
@@ -751,6 +763,16 @@ void SyncBackendHost::Core::HandleActionableErrorEventOnFrontendLoop(
host_->frontend_->OnActionableError(sync_error);
}
+void SyncBackendHost::Core::HandleUnrecoverableErrorOnFrontendLoop(
+ const tracked_objects::Location& location,
+ const std::string& message) {
+ if (!host_ || !host_->frontend_)
+ return;
+ DCHECK_EQ(MessageLoop::current(), host_->frontend_loop_);
+ host_->frontend_->OnUnrecoverableError(location, message);
+}
+
+
void SyncBackendHost::Core::HandleAuthErrorEventOnFrontendLoop(
const GoogleServiceAuthError& new_auth_error) {
if (!host_ || !host_->frontend_)

Powered by Google App Engine
This is Rietveld 408576698