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

Unified Diff: components/history/core/browser/top_sites_impl.cc

Issue 1815363002: Add RetainedRef uses where needed. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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/history/core/browser/top_sites_impl.cc
diff --git a/components/history/core/browser/top_sites_impl.cc b/components/history/core/browser/top_sites_impl.cc
index fb8e080a2045e60a1f63894885465430ba753e8d..2133076db6575220fbb91d728882b76fd5d70f61 100644
--- a/components/history/core/browser/top_sites_impl.cc
+++ b/components/history/core/browser/top_sites_impl.cc
@@ -217,9 +217,10 @@ void TopSitesImpl::GetMostVisitedURLs(
if (!loaded_) {
// A request came in before we finished loading. Store the callback and
// we'll run it on current thread when we finish loading.
- pending_callbacks_.push_back(base::Bind(
- &RunOrPostGetMostVisitedURLsCallback,
- base::ThreadTaskRunnerHandle::Get(), include_forced_urls, callback));
+ pending_callbacks_.push_back(
+ base::Bind(&RunOrPostGetMostVisitedURLsCallback,
+ base::RetainedRef(base::ThreadTaskRunnerHandle::Get()),
+ include_forced_urls, callback));
return;
}
if (include_forced_urls) {
« no previous file with comments | « components/drive/file_system/search_operation.cc ('k') | components/scheduler/base/task_queue_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698