Update for changes to net::FileProtocolHandler in Chrome 31
I just copied the way that Chrome initializes this object.
This commit is contained in:
parent
265076f19a
commit
cfeddb5bcb
1 changed files with 6 additions and 1 deletions
|
@ -9,6 +9,7 @@
|
||||||
#include "browser/network_delegate.h"
|
#include "browser/network_delegate.h"
|
||||||
|
|
||||||
#include "base/strings/string_util.h"
|
#include "base/strings/string_util.h"
|
||||||
|
#include "base/threading/sequenced_worker_pool.h"
|
||||||
#include "base/threading/worker_pool.h"
|
#include "base/threading/worker_pool.h"
|
||||||
#include "content/public/browser/browser_thread.h"
|
#include "content/public/browser/browser_thread.h"
|
||||||
#include "content/public/browser/cookie_store_factory.h"
|
#include "content/public/browser/cookie_store_factory.h"
|
||||||
|
@ -142,7 +143,11 @@ net::URLRequestContext* URLRequestContextGetter::GetURLRequestContext() {
|
||||||
job_factory->SetProtocolHandler(
|
job_factory->SetProtocolHandler(
|
||||||
chrome::kDataScheme, new net::DataProtocolHandler);
|
chrome::kDataScheme, new net::DataProtocolHandler);
|
||||||
job_factory->SetProtocolHandler(
|
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());
|
storage_->set_job_factory(job_factory.release());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue