| Index: third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.cpp
|
| diff --git a/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.cpp b/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.cpp
|
| index 6acd6833d14aa1989cea9188bbb255a3c6f07ea9..27accf2113b4f6256fa2e7cffdeb23fa24b248bd 100644
|
| --- a/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.cpp
|
| +++ b/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.cpp
|
| @@ -38,6 +38,7 @@
|
| #include "core/inspector/ConsoleMessage.h"
|
| #include "core/loader/FrameLoadRequest.h"
|
| #include "core/loader/ThreadableLoadingContext.h"
|
| +#include "core/loader/WorkerFetchContext.h"
|
| #include "core/probe/CoreProbes.h"
|
| #include "core/workers/ParentFrameTaskRunners.h"
|
| #include "core/workers/WorkerClients.h"
|
| @@ -433,6 +434,18 @@ void WebEmbeddedWorkerImpl::StartWorkerThread() {
|
| worker_clients,
|
| WTF::WrapUnique(worker_context_client_->CreateServiceWorkerProvider()));
|
|
|
| + std::unique_ptr<WebWorkerFetchContextInfo> web_worker_fetch_context_info =
|
| + WTF::WrapUnique(
|
| + worker_context_client_->CreateServiceWorkerFetchContextInfo());
|
| + // |web_worker_fetch_context_info| is null if off-main-thread-fetch is
|
| + // disabled.
|
| + if (web_worker_fetch_context_info) {
|
| + // TODO(horo): Set more information about the context (ex: DataSaverEnabled)
|
| + // to |web_worker_fetch_context_info|.
|
| + ProvideWorkerFetchContextInfoToWorker(
|
| + worker_clients, std::move(web_worker_fetch_context_info));
|
| + }
|
| +
|
| // We need to set the CSP to both the shadow page's document and the
|
| // ServiceWorkerGlobalScope.
|
| document->InitContentSecurityPolicy(
|
|
|