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

Side by Side Diff: content/browser/loader/resource_loader.cc

Issue 2356013002: Remove unused was_fetched_via_proxy members (Closed)
Patch Set: remove even more! Created 4 years, 3 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
« no previous file with comments | « no previous file | content/child/web_url_loader_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/browser/loader/resource_loader.h" 5 #include "content/browser/loader/resource_loader.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 response->head.headers = request->response_headers(); 57 response->head.headers = request->response_headers();
58 request->GetCharset(&response->head.charset); 58 request->GetCharset(&response->head.charset);
59 response->head.content_length = request->GetExpectedContentSize(); 59 response->head.content_length = request->GetExpectedContentSize();
60 request->GetMimeType(&response->head.mime_type); 60 request->GetMimeType(&response->head.mime_type);
61 net::HttpResponseInfo response_info = request->response_info(); 61 net::HttpResponseInfo response_info = request->response_info();
62 response->head.was_fetched_via_spdy = response_info.was_fetched_via_spdy; 62 response->head.was_fetched_via_spdy = response_info.was_fetched_via_spdy;
63 response->head.was_alpn_negotiated = response_info.was_alpn_negotiated; 63 response->head.was_alpn_negotiated = response_info.was_alpn_negotiated;
64 response->head.alpn_negotiated_protocol = 64 response->head.alpn_negotiated_protocol =
65 response_info.alpn_negotiated_protocol; 65 response_info.alpn_negotiated_protocol;
66 response->head.connection_info = response_info.connection_info; 66 response->head.connection_info = response_info.connection_info;
67 response->head.was_fetched_via_proxy = request->was_fetched_via_proxy();
68 response->head.proxy_server = response_info.proxy_server;
69 response->head.socket_address = response_info.socket_address; 67 response->head.socket_address = response_info.socket_address;
70 const content::ResourceRequestInfo* request_info = 68 const content::ResourceRequestInfo* request_info =
71 content::ResourceRequestInfo::ForRequest(request); 69 content::ResourceRequestInfo::ForRequest(request);
72 if (request_info) 70 if (request_info)
73 response->head.is_using_lofi = request_info->IsUsingLoFi(); 71 response->head.is_using_lofi = request_info->IsUsingLoFi();
74 72
75 response->head.effective_connection_type = 73 response->head.effective_connection_type =
76 net::EFFECTIVE_CONNECTION_TYPE_UNKNOWN; 74 net::EFFECTIVE_CONNECTION_TYPE_UNKNOWN;
77 75
78 if (info->GetResourceType() == RESOURCE_TYPE_MAIN_FRAME) { 76 if (info->GetResourceType() == RESOURCE_TYPE_MAIN_FRAME) {
(...skipping 635 matching lines...) Expand 10 before | Expand all | Expand 10 after
714 } 712 }
715 713
716 UMA_HISTOGRAM_ENUMERATION("Net.Prefetch.Pattern", status, STATUS_MAX); 714 UMA_HISTOGRAM_ENUMERATION("Net.Prefetch.Pattern", status, STATUS_MAX);
717 } else if (request_->response_info().unused_since_prefetch) { 715 } else if (request_->response_info().unused_since_prefetch) {
718 TimeDelta total_time = base::TimeTicks::Now() - request_->creation_time(); 716 TimeDelta total_time = base::TimeTicks::Now() - request_->creation_time();
719 UMA_HISTOGRAM_TIMES("Net.Prefetch.TimeSpentOnPrefetchHit", total_time); 717 UMA_HISTOGRAM_TIMES("Net.Prefetch.TimeSpentOnPrefetchHit", total_time);
720 } 718 }
721 } 719 }
722 720
723 } // namespace content 721 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/child/web_url_loader_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698