Index: components/history/core/browser/history_service.cc |
diff --git a/components/history/core/browser/history_service.cc b/components/history/core/browser/history_service.cc |
index 28bdd51cdb5cca43617ab5ff20c9656477a6cd05..fafadfb240e70eb1f3e558f1ac06bb5f2c7f11c5 100644 |
--- a/components/history/core/browser/history_service.cc |
+++ b/components/history/core/browser/history_service.cc |
@@ -667,6 +667,20 @@ base::CancelableTaskTracker::TaskId HistoryService::QueryURL( |
base::Owned(query_url_result))); |
} |
+// Statistics ------------------------------------------------------------------ |
+ |
+base::CancelableTaskTracker::TaskId HistoryService::GetHistoryCount( |
+ const GetHistoryCountCallback& callback, |
+ base::CancelableTaskTracker* tracker) { |
+ DCHECK(thread_) << "History service being called after cleanup"; |
+ DCHECK(thread_checker_.CalledOnValidThread()); |
+ |
+ return tracker->PostTaskAndReplyWithResult( |
+ thread_->task_runner().get(), FROM_HERE, |
+ base::Bind(&HistoryBackend::GetHistoryCount, history_backend_.get()), |
+ callback); |
+} |
+ |
// Downloads ------------------------------------------------------------------- |
// Handle creation of a download by creating an entry in the history service's |