Chromium Code Reviews| Index: net/url_request/url_request_context_builder.cc |
| diff --git a/net/url_request/url_request_context_builder.cc b/net/url_request/url_request_context_builder.cc |
| index 540dfc1082bd81c127f69468b7666235c5f60891..bbeb6d954bf41352cc89580e8ea6b4a7a269a5cf 100644 |
| --- a/net/url_request/url_request_context_builder.cc |
| +++ b/net/url_request/url_request_context_builder.cc |
| @@ -184,13 +184,17 @@ URLRequestContextBuilder::HttpNetworkSessionParams::HttpNetworkSessionParams() |
| URLRequestContextBuilder::HttpNetworkSessionParams::~HttpNetworkSessionParams() |
| {} |
| -URLRequestContextBuilder::URLRequestContextBuilder() |
| +URLRequestContextBuilder::URLRequestContextBuilder( |
| + const scoped_refptr<base::TaskRunner>& task_runner) |
|
akalin
2013/08/15 17:43:05
don't think you need this parameter -- see context
|
| : data_enabled_(false), |
| file_enabled_(false), |
| #if !defined(DISABLE_FTP_SUPPORT) |
| ftp_enabled_(false), |
| #endif |
| - http_cache_enabled_(true) {} |
| + http_cache_enabled_(true), |
| + task_runner_(task_runner) { |
| +} |
| + |
| URLRequestContextBuilder::~URLRequestContextBuilder() {} |
| #if defined(OS_LINUX) || defined(OS_ANDROID) |
| @@ -301,7 +305,8 @@ URLRequestContext* URLRequestContextBuilder::Build() { |
| if (data_enabled_) |
| job_factory->SetProtocolHandler("data", new DataProtocolHandler); |
| if (file_enabled_) |
| - job_factory->SetProtocolHandler("file", new FileProtocolHandler); |
| + job_factory->SetProtocolHandler("file", |
| + new FileProtocolHandler(task_runner_)); |
| #if !defined(DISABLE_FTP_SUPPORT) |
| if (ftp_enabled_) { |
| ftp_transaction_factory_.reset( |