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

Side by Side Diff: content/child/web_url_loader_impl.cc

Issue 2235543002: Keep track of how many documents had a resource intercepted by foreign fetch. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/child/web_url_loader_impl.h" 5 #include "content/child/web_url_loader_impl.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <memory> 10 #include <memory>
(...skipping 943 matching lines...) Expand 10 before | Expand all | Expand 10 after
954 response->setWasCached(!info.load_timing.request_start_time.is_null() && 954 response->setWasCached(!info.load_timing.request_start_time.is_null() &&
955 info.response_time < info.load_timing.request_start_time); 955 info.response_time < info.load_timing.request_start_time);
956 response->setRemoteIPAddress( 956 response->setRemoteIPAddress(
957 WebString::fromUTF8(info.socket_address.HostForURL())); 957 WebString::fromUTF8(info.socket_address.HostForURL()));
958 response->setRemotePort(info.socket_address.port()); 958 response->setRemotePort(info.socket_address.port());
959 response->setConnectionID(info.load_timing.socket_log_id); 959 response->setConnectionID(info.load_timing.socket_log_id);
960 response->setConnectionReused(info.load_timing.socket_reused); 960 response->setConnectionReused(info.load_timing.socket_reused);
961 response->setDownloadFilePath(info.download_file_path.AsUTF16Unsafe()); 961 response->setDownloadFilePath(info.download_file_path.AsUTF16Unsafe());
962 response->setWasFetchedViaSPDY(info.was_fetched_via_spdy); 962 response->setWasFetchedViaSPDY(info.was_fetched_via_spdy);
963 response->setWasFetchedViaServiceWorker(info.was_fetched_via_service_worker); 963 response->setWasFetchedViaServiceWorker(info.was_fetched_via_service_worker);
964 response->setWasFetchedViaForeignFetch(info.was_fetched_via_foreign_fetch);
964 response->setWasFallbackRequiredByServiceWorker( 965 response->setWasFallbackRequiredByServiceWorker(
965 info.was_fallback_required_by_service_worker); 966 info.was_fallback_required_by_service_worker);
966 response->setServiceWorkerResponseType(info.response_type_via_service_worker); 967 response->setServiceWorkerResponseType(info.response_type_via_service_worker);
967 response->setOriginalURLViaServiceWorker( 968 response->setOriginalURLViaServiceWorker(
968 info.original_url_via_service_worker); 969 info.original_url_via_service_worker);
969 response->setCacheStorageCacheName( 970 response->setCacheStorageCacheName(
970 info.is_in_cache_storage 971 info.is_in_cache_storage
971 ? blink::WebString::fromUTF8(info.cache_storage_cache_name) 972 ? blink::WebString::fromUTF8(info.cache_storage_cache_name)
972 : blink::WebString()); 973 : blink::WebString());
973 blink::WebVector<blink::WebString> cors_exposed_header_names( 974 blink::WebVector<blink::WebString> cors_exposed_header_names(
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
1212 response->clearHTTPHeaderField(webStringName); 1213 response->clearHTTPHeaderField(webStringName);
1213 while (response_headers->EnumerateHeader(&iterator, name, &value)) { 1214 while (response_headers->EnumerateHeader(&iterator, name, &value)) {
1214 response->addHTTPHeaderField(webStringName, 1215 response->addHTTPHeaderField(webStringName,
1215 WebString::fromLatin1(value)); 1216 WebString::fromLatin1(value));
1216 } 1217 }
1217 } 1218 }
1218 return true; 1219 return true;
1219 } 1220 }
1220 1221
1221 } // namespace content 1222 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/service_worker/service_worker_url_request_job.cc ('k') | content/public/common/resource_response.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698