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

Side by Side Diff: content/browser/frame_host/navigator_impl.cc

Issue 1002803002: Classify navigations without page id in parallel to the existing classifier. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase again Created 5 years, 8 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/frame_host/navigator_impl.h" 5 #include "content/browser/frame_host/navigator_impl.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/metrics/histogram.h" 8 #include "base/metrics/histogram.h"
9 #include "base/time/time.h" 9 #include "base/time/time.h"
10 #include "content/browser/frame_host/frame_tree.h" 10 #include "content/browser/frame_host/frame_tree.h"
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 170
171 void NavigatorImpl::DidFailProvisionalLoadWithError( 171 void NavigatorImpl::DidFailProvisionalLoadWithError(
172 RenderFrameHostImpl* render_frame_host, 172 RenderFrameHostImpl* render_frame_host,
173 const FrameHostMsg_DidFailProvisionalLoadWithError_Params& params) { 173 const FrameHostMsg_DidFailProvisionalLoadWithError_Params& params) {
174 VLOG(1) << "Failed Provisional Load: " << params.url.possibly_invalid_spec() 174 VLOG(1) << "Failed Provisional Load: " << params.url.possibly_invalid_spec()
175 << ", error_code: " << params.error_code 175 << ", error_code: " << params.error_code
176 << ", error_description: " << params.error_description 176 << ", error_description: " << params.error_description
177 << ", showing_repost_interstitial: " << 177 << ", showing_repost_interstitial: " <<
178 params.showing_repost_interstitial 178 params.showing_repost_interstitial
179 << ", frame_id: " << render_frame_host->GetRoutingID(); 179 << ", frame_id: " << render_frame_host->GetRoutingID();
180 if (controller_->GetPendingEntry() && params.nav_entry_id != 0 &&
mnaganov (inactive) 2015/04/22 09:29:03 This change is causing ClientOnPageFinishedTest#te
Avi (use Gerrit) 2015/04/22 18:31:50 Ah. I will look into this, and will call out when
181 controller_->GetPendingEntry()->GetUniqueID() != params.nav_entry_id) {
182 // If this failure is browser-initiated but isn't that of the pending entry,
183 // ignore it. This can happen if there is an outstanding request that never
184 // committed, and then a user makes a new request. In that case the new
185 // request will be the pending entry, and the attempt to load the new
186 // request will cause a failure message from the old request.
187 return;
188 }
189
180 GURL validated_url(params.url); 190 GURL validated_url(params.url);
181 RenderProcessHost* render_process_host = render_frame_host->GetProcess(); 191 RenderProcessHost* render_process_host = render_frame_host->GetProcess();
182 render_process_host->FilterURL(false, &validated_url); 192 render_process_host->FilterURL(false, &validated_url);
183 193
184 if (net::ERR_ABORTED == params.error_code) { 194 if (net::ERR_ABORTED == params.error_code) {
185 // EVIL HACK ALERT! Ignore failed loads when we're showing interstitials. 195 // EVIL HACK ALERT! Ignore failed loads when we're showing interstitials.
186 // This means that the interstitial won't be torn down properly, which is 196 // This means that the interstitial won't be torn down properly, which is
187 // bad. But if we have an interstitial, go back to another tab type, and 197 // bad. But if we have an interstitial, go back to another tab type, and
188 // then load the same interstitial again, we could end up getting the first 198 // then load the same interstitial again, we could end up getting the first
189 // interstitial's "failed" message (as a result of the cancel) when we're on 199 // interstitial's "failed" message (as a result of the cancel) when we're on
(...skipping 697 matching lines...) Expand 10 before | Expand all | Expand 10 after
887 "Navigation.TimeToCommit_ExistingRenderer_BeforeUnloadDiscounted", 897 "Navigation.TimeToCommit_ExistingRenderer_BeforeUnloadDiscounted",
888 time_to_commit); 898 time_to_commit);
889 UMA_HISTOGRAM_TIMES( 899 UMA_HISTOGRAM_TIMES(
890 "Navigation.TimeToURLJobStart_ExistingRenderer_BeforeUnloadDiscounted", 900 "Navigation.TimeToURLJobStart_ExistingRenderer_BeforeUnloadDiscounted",
891 time_to_network); 901 time_to_network);
892 } 902 }
893 navigation_data_.reset(); 903 navigation_data_.reset();
894 } 904 }
895 905
896 } // namespace content 906 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698