| 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 044495e8c15477c6feb9d26f3b8e58b564fdebe0..d56e391d04b3dcc5e53741f207c8f6d068abdabc 100644
|
| --- a/chrome/browser/page_load_metrics/metrics_web_contents_observer.cc
|
| +++ b/chrome/browser/page_load_metrics/metrics_web_contents_observer.cc
|
| @@ -178,11 +178,10 @@ void MetricsWebContentsObserver::WillStartNavigationRequest(
|
| // WebContent's opener. This is more accurate than using referrers due to
|
| // referrer sanitizing and origin referrers. Note that this could potentially
|
| // be inaccurate if the opener has since navigated.
|
| - content::WebContents* opener = web_contents()->GetOpener();
|
| - const GURL& opener_url =
|
| - !has_navigated_ && opener
|
| - ? web_contents()->GetOpener()->GetLastCommittedURL()
|
| - : GURL::EmptyGURL();
|
| + content::RenderFrameHost* opener = web_contents()->GetOpener();
|
| + const GURL& opener_url = !has_navigated_ && opener
|
| + ? opener->GetLastCommittedURL()
|
| + : GURL::EmptyGURL();
|
| const GURL& currently_committed_url =
|
| committed_load_ ? committed_load_->url() : opener_url;
|
| has_navigated_ = true;
|
|
|