Index: chrome/browser/page_load_metrics/metrics_web_contents_observer.cc |
diff --git a/chrome/browser/page_load_metrics/metrics_web_contents_observer.cc b/chrome/browser/page_load_metrics/metrics_web_contents_observer.cc |
index 3e41fa893e06c3249e92a862b19183e438b6c8f6..b69818c3588b04e729d400ae222525911e405eb0 100644 |
--- a/chrome/browser/page_load_metrics/metrics_web_contents_observer.cc |
+++ b/chrome/browser/page_load_metrics/metrics_web_contents_observer.cc |
@@ -253,6 +253,8 @@ PageLoadTracker* MetricsWebContentsObserver::GetTrackerOrNullForRequest( |
} |
void MetricsWebContentsObserver::OnRequestComplete( |
+ const GURL& url, |
+ int frame_tree_node_id, |
const content::GlobalRequestID& request_id, |
content::ResourceType resource_type, |
bool was_cached, |
@@ -265,7 +267,8 @@ void MetricsWebContentsObserver::OnRequestComplete( |
GetTrackerOrNullForRequest(request_id, resource_type, creation_time); |
if (tracker) { |
ExtraRequestInfo extra_request_info( |
- was_cached, raw_body_bytes, was_cached ? 0 : original_content_length, |
+ url, frame_tree_node_id, was_cached, raw_body_bytes, |
+ was_cached ? 0 : original_content_length, |
std::move(data_reduction_proxy_data)); |
tracker->OnLoadedResource(extra_request_info); |
} |
@@ -289,8 +292,10 @@ MetricsWebContentsObserver::GetPageLoadExtraInfoForCommittedLoad() { |
void MetricsWebContentsObserver::DidFinishNavigation( |
content::NavigationHandle* navigation_handle) { |
- if (!navigation_handle->IsInMainFrame()) |
+ if (!navigation_handle->IsInMainFrame() && committed_load_) { |
Bryan McQuade
2017/04/25 16:36:44
i think we should still return early if it's not a
Bryan McQuade
2017/04/25 16:37:59
sorry, my brain has apparently not fired up yet. p
|
+ committed_load_->DidFinishSubFrameNavigation(navigation_handle); |
return; |
+ } |
std::unique_ptr<PageLoadTracker> finished_nav( |
std::move(provisional_loads_[navigation_handle])); |