From cfeddb5bcbbeaf3d9593e394255066465d49836c Mon Sep 17 00:00:00 2001 From: Adam Roben Date: Mon, 2 Dec 2013 11:39:26 -0500 Subject: [PATCH] Update for changes to net::FileProtocolHandler in Chrome 31 I just copied the way that Chrome initializes this object. --- brightray/browser/url_request_context_getter.cc | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/brightray/browser/url_request_context_getter.cc b/brightray/browser/url_request_context_getter.cc index ecba106e96b4..8d2abf5a32c6 100644 --- a/brightray/browser/url_request_context_getter.cc +++ b/brightray/browser/url_request_context_getter.cc @@ -9,6 +9,7 @@ #include "browser/network_delegate.h" #include "base/strings/string_util.h" +#include "base/threading/sequenced_worker_pool.h" #include "base/threading/worker_pool.h" #include "content/public/browser/browser_thread.h" #include "content/public/browser/cookie_store_factory.h" @@ -142,7 +143,11 @@ net::URLRequestContext* URLRequestContextGetter::GetURLRequestContext() { job_factory->SetProtocolHandler( chrome::kDataScheme, new net::DataProtocolHandler); job_factory->SetProtocolHandler( - chrome::kFileScheme, new net::FileProtocolHandler); + chrome::kFileScheme, + new net::FileProtocolHandler( + content::BrowserThread::GetBlockingPool()-> + GetTaskRunnerWithShutdownBehavior( + base::SequencedWorkerPool::SKIP_ON_SHUTDOWN))); storage_->set_job_factory(job_factory.release()); }