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

Unified Diff: content/browser/download/download_request_core.cc

Issue 2890853002: Downloads: replace BrowserThread::FILE with task scheduler. (Closed)
Patch Set: Address Avi's comments. Created 3 years, 5 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: content/browser/download/download_request_core.cc
diff --git a/content/browser/download/download_request_core.cc b/content/browser/download/download_request_core.cc
index ded98502547fb259e1e1580363f508003056323d..92a9491ea0cefc7d14089fd402827d4165ab8ec6 100644
--- a/content/browser/download/download_request_core.cc
+++ b/content/browser/download/download_request_core.cc
@@ -23,6 +23,7 @@
#include "content/browser/download/download_manager_impl.h"
#include "content/browser/download/download_request_handle.h"
#include "content/browser/download/download_stats.h"
+#include "content/browser/download/download_task_runner.h"
#include "content/browser/loader/resource_dispatcher_host_impl.h"
#include "content/browser/service_manager/service_manager_context.h"
#include "content/public/browser/browser_thread.h"
@@ -307,8 +308,7 @@ bool DownloadRequestCore::OnResponseStarted(
// Create the ByteStream for sending data to the download sink.
std::unique_ptr<ByteStreamReader> stream_reader;
- CreateByteStream(base::ThreadTaskRunnerHandle::Get(),
- BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE),
+ CreateByteStream(base::ThreadTaskRunnerHandle::Get(), GetDownloadTaskRunner(),
kDownloadByteStreamSize, &stream_writer_, &stream_reader);
stream_writer_->RegisterCallback(
base::Bind(&DownloadRequestCore::ResumeRequest, AsWeakPtr()));
« no previous file with comments | « content/browser/download/download_manager_impl_unittest.cc ('k') | content/browser/download/download_resource_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698