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

Side by Side Diff: chrome/browser/renderer_host/resource_dispatcher_host.cc

Issue 5803003: Don't include ERR_ABORTED in net error histogram (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 10 years 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc e-loading
6 6
7 #include "chrome/browser/renderer_host/resource_dispatcher_host.h" 7 #include "chrome/browser/renderer_host/resource_dispatcher_host.h"
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 1473 matching lines...) Expand 10 before | Expand all | Expand 10 after
1484 return *bytes_read != 0; 1484 return *bytes_read != 0;
1485 } 1485 }
1486 1486
1487 void ResourceDispatcherHost::OnResponseCompleted(net::URLRequest* request) { 1487 void ResourceDispatcherHost::OnResponseCompleted(net::URLRequest* request) {
1488 VLOG(1) << "OnResponseCompleted: " << request->url().spec(); 1488 VLOG(1) << "OnResponseCompleted: " << request->url().spec();
1489 ResourceDispatcherHostRequestInfo* info = InfoForRequest(request); 1489 ResourceDispatcherHostRequestInfo* info = InfoForRequest(request);
1490 1490
1491 // If the load for a main frame has failed, track it in a histogram, 1491 // If the load for a main frame has failed, track it in a histogram,
1492 // since it will probably cause the user to see an error page. 1492 // since it will probably cause the user to see an error page.
1493 if (!request->status().is_success() && 1493 if (!request->status().is_success() &&
1494 info->resource_type() == ResourceType::MAIN_FRAME) { 1494 info->resource_type() == ResourceType::MAIN_FRAME &&
1495 request->status().os_error() != net::ERR_ABORTED) {
1495 UMA_HISTOGRAM_CUSTOM_ENUMERATION("Net.ErrorCodesForMainFrame", 1496 UMA_HISTOGRAM_CUSTOM_ENUMERATION("Net.ErrorCodesForMainFrame",
1496 -request->status().os_error(), 1497 -request->status().os_error(),
1497 GetAllNetErrorCodes()); 1498 GetAllNetErrorCodes());
1498 } 1499 }
1499 1500
1500 std::string security_info; 1501 std::string security_info;
1501 const net::SSLInfo& ssl_info = request->ssl_info(); 1502 const net::SSLInfo& ssl_info = request->ssl_info();
1502 if (ssl_info.cert != NULL) { 1503 if (ssl_info.cert != NULL) {
1503 int cert_id = CertStore::GetInstance()->StoreCert(ssl_info.cert, 1504 int cert_id = CertStore::GetInstance()->StoreCert(ssl_info.cert,
1504 info->child_id()); 1505 info->child_id());
(...skipping 455 matching lines...) Expand 10 before | Expand all | Expand 10 after
1960 return is_prefetch_enabled_; 1961 return is_prefetch_enabled_;
1961 } 1962 }
1962 1963
1963 // static 1964 // static
1964 void ResourceDispatcherHost::set_is_prefetch_enabled(bool value) { 1965 void ResourceDispatcherHost::set_is_prefetch_enabled(bool value) {
1965 is_prefetch_enabled_ = value; 1966 is_prefetch_enabled_ = value;
1966 } 1967 }
1967 1968
1968 // static 1969 // static
1969 bool ResourceDispatcherHost::is_prefetch_enabled_ = false; 1970 bool ResourceDispatcherHost::is_prefetch_enabled_ = false;
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698