Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1476)

Unified Diff: content/browser/service_worker/service_worker_fetch_dispatcher.cc

Issue 2645363002: Copy the original request header for navigation preload requests (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/serviceworker/navigation-preload/request-headers.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/service_worker/service_worker_fetch_dispatcher.cc
diff --git a/content/browser/service_worker/service_worker_fetch_dispatcher.cc b/content/browser/service_worker/service_worker_fetch_dispatcher.cc
index 85cf9d7db3ad27aae10f29f51f41cb6f0955f03d..039811c495809dbe32b2450255b5010db1054ae5 100644
--- a/content/browser/service_worker/service_worker_fetch_dispatcher.cc
+++ b/content/browser/service_worker/service_worker_fetch_dispatcher.cc
@@ -466,7 +466,8 @@ bool ServiceWorkerFetchDispatcher::MaybeStartNavigationPreload(
ServiceWorkerMetrics::RecordNavigationPreloadRequestHeaderSize(
version_->navigation_preload_state().header.length());
request.headers = "Service-Worker-Navigation-Preload: " +
- version_->navigation_preload_state().header;
+ version_->navigation_preload_state().header + "\r\n" +
+ original_request->extra_request_headers().ToString();
const int request_id = ResourceDispatcherHostImpl::Get()->MakeRequestID();
DCHECK_LT(request_id, -1);
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/serviceworker/navigation-preload/request-headers.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698