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

Unified Diff: chrome/browser/sync/profile_sync_service_typed_url_unittest.cc

Issue 9264062: [Sync] Consolidate DataTypeController methods that post on the backend thread (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add suppressions Created 8 years, 11 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 | « chrome/browser/sync/glue/typed_url_data_type_controller.cc ('k') | tools/heapcheck/suppressions.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/profile_sync_service_typed_url_unittest.cc
diff --git a/chrome/browser/sync/profile_sync_service_typed_url_unittest.cc b/chrome/browser/sync/profile_sync_service_typed_url_unittest.cc
index fd0ac0abfff354ca1c835fb9cae9edfeeb51711b..7629c6f9ebf71ffebea026e659ce229ced1317be 100644
--- a/chrome/browser/sync/profile_sync_service_typed_url_unittest.cc
+++ b/chrome/browser/sync/profile_sync_service_typed_url_unittest.cc
@@ -119,9 +119,12 @@ void RunOnDBThreadCallback(HistoryBackend* backend,
}
ACTION_P2(RunTaskOnDBThread, thread, backend) {
- thread->message_loop()->PostTask(
- FROM_HERE, base::Bind(&RunOnDBThreadCallback, base::Unretained(backend),
- base::Unretained(arg0)));
+ // ScheduleDBTask takes ownership of its task argument, so we
+ // should, too.
+ scoped_refptr<HistoryDBTask> task(arg0);
+ thread->message_loop()->PostTask(
+ FROM_HERE, base::Bind(&RunOnDBThreadCallback, base::Unretained(backend),
+ task));
}
ACTION_P4(MakeTypedUrlSyncComponents, profile, service, hb, dtc) {
« no previous file with comments | « chrome/browser/sync/glue/typed_url_data_type_controller.cc ('k') | tools/heapcheck/suppressions.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698