| Index: chrome/browser/profiles/profile_impl_io_data.cc
|
| diff --git a/chrome/browser/profiles/profile_impl_io_data.cc b/chrome/browser/profiles/profile_impl_io_data.cc
|
| index 8bb36096c0e0c00d37ffda4b013bb66bfb96566c..246b8ff1ce87c870fad6133af99a1abea71dbf78 100644
|
| --- a/chrome/browser/profiles/profile_impl_io_data.cc
|
| +++ b/chrome/browser/profiles/profile_impl_io_data.cc
|
| @@ -200,26 +200,26 @@ void ProfileImplIOData::Handle::Init(
|
| base::SequencedWorkerPool::SKIP_ON_SHUTDOWN);
|
| std::unique_ptr<data_reduction_proxy::DataStore> store(
|
| new data_reduction_proxy::DataStoreImpl(profile_path));
|
| DataReductionProxyChromeSettingsFactory::GetForBrowserContext(profile_)
|
| ->InitDataReductionProxySettings(
|
| io_data_->data_reduction_proxy_io_data(), profile_->GetPrefs(),
|
| profile_->GetRequestContext(), std::move(store),
|
| BrowserThread::GetTaskRunnerForThread(BrowserThread::UI),
|
| db_task_runner);
|
|
|
| - io_data_->set_previews_io_data(base::MakeUnique<previews::PreviewsIOData>(
|
| + io_data_->previews_io_data_ = base::MakeUnique<previews::PreviewsIOData>(
|
| BrowserThread::GetTaskRunnerForThread(BrowserThread::UI),
|
| - BrowserThread::GetTaskRunnerForThread(BrowserThread::IO)));
|
| + BrowserThread::GetTaskRunnerForThread(BrowserThread::IO));
|
| PreviewsServiceFactory::GetForProfile(profile_)->set_previews_ui_service(
|
| base::MakeUnique<previews::PreviewsUIService>(
|
| - io_data_->previews_io_data(),
|
| + io_data_->previews_io_data_.get(),
|
| BrowserThread::GetTaskRunnerForThread(BrowserThread::IO), nullptr));
|
| }
|
|
|
| content::ResourceContext*
|
| ProfileImplIOData::Handle::GetResourceContext() const {
|
| DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
| LazyInitialize();
|
| return GetResourceContextNoInit();
|
| }
|
|
|
| @@ -542,21 +542,22 @@ void ProfileImplIOData::InitializeInternal(
|
| new net::FtpNetworkLayer(io_thread_globals->host_resolver.get()));
|
| #endif // !defined(DISABLE_FTP_SUPPORT)
|
|
|
| std::unique_ptr<net::URLRequestJobFactoryImpl> main_job_factory(
|
| new net::URLRequestJobFactoryImpl());
|
| InstallProtocolHandlers(main_job_factory.get(), protocol_handlers);
|
|
|
| // Install the Offline Page Interceptor.
|
| #if defined(OS_ANDROID)
|
| request_interceptors.push_back(std::unique_ptr<net::URLRequestInterceptor>(
|
| - new offline_pages::OfflinePageRequestInterceptor()));
|
| + new offline_pages::OfflinePageRequestInterceptor(
|
| + previews_io_data_.get())));
|
| #endif
|
|
|
| // The data reduction proxy interceptor should be as close to the network
|
| // as possible.
|
| request_interceptors.insert(
|
| request_interceptors.begin(),
|
| data_reduction_proxy_io_data()->CreateInterceptor().release());
|
| main_job_factory_ = SetUpJobFactoryDefaults(
|
| std::move(main_job_factory), std::move(request_interceptors),
|
| std::move(profile_params->protocol_handler_interceptor),
|
|
|