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

Unified Diff: sync/internal_api/public/engine/passive_model_worker.cc

Issue 14046031: Worker changes to prepare for lock-free shutdown. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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/internal_api/public/engine/passive_model_worker.cc
diff --git a/sync/internal_api/public/engine/passive_model_worker.cc b/sync/internal_api/public/engine/passive_model_worker.cc
index 10d20ee4f87be8773483ca2d8074283b0e76395f..17e45fc4a7d194f024d268003c4202f01e532199 100644
--- a/sync/internal_api/public/engine/passive_model_worker.cc
+++ b/sync/internal_api/public/engine/passive_model_worker.cc
@@ -8,14 +8,22 @@
namespace syncer {
-PassiveModelWorker::PassiveModelWorker(const MessageLoop* sync_loop)
- : sync_loop_(sync_loop) {}
+PassiveModelWorker::PassiveModelWorker(const MessageLoop* sync_loop,
+ WorkerObserver* observer)
+ : ModelSafeWorker(observer),
+ sync_loop_(sync_loop) {
+}
PassiveModelWorker::~PassiveModelWorker() {
}
+void PassiveModelWorker::RegisterForLoopDestruction() {
+ NOTREACHED();
+}
+
SyncerError PassiveModelWorker::DoWorkAndWaitUntilDone(
- const WorkCallback& work) {
+ const WorkCallback& work,
+ base::WaitableEvent* done) {
DCHECK_EQ(MessageLoop::current(), sync_loop_);
// Simply do the work on the current thread.
return work.Run();

Powered by Google App Engine
This is Rietveld 408576698