| Index: content/browser/security_exploit_browsertest.cc
|
| diff --git a/content/browser/security_exploit_browsertest.cc b/content/browser/security_exploit_browsertest.cc
|
| index cf3b7f759ddf469ae49594a9e222b8cb07d94a9f..b28dae0b944bb304d889f825f16d09f1e41cbefc 100644
|
| --- a/content/browser/security_exploit_browsertest.cc
|
| +++ b/content/browser/security_exploit_browsertest.cc
|
| @@ -73,15 +73,22 @@ RenderViewHostImpl* PrepareToDuplicateHosts(Shell* shell,
|
| Referrer(), CURRENT_TAB, false, true);
|
|
|
| // Since the navigation above requires a cross-process swap, there will be a
|
| - // pending RenderViewHost. Ensure it exists and is in a different process
|
| - // than the initial page.
|
| - RenderViewHostImpl* pending_rvh =
|
| - wc->GetRenderManagerForTesting()->pending_render_view_host();
|
| - EXPECT_TRUE(pending_rvh != NULL);
|
| - EXPECT_NE(shell->web_contents()->GetRenderViewHost()->GetProcess()->GetID(),
|
| - pending_rvh->GetProcess()->GetID());
|
| + // speculative/pending RenderFrameHost. Ensure it exists and is in a different
|
| + // process than the initial page.
|
| + RenderFrameHostImpl* next_rfh;
|
| + if (base::CommandLine::ForCurrentProcess()->HasSwitch(
|
| + switches::kEnableBrowserSideNavigation)) {
|
| + next_rfh =
|
| + wc->GetRenderManagerForTesting()->speculative_frame_host_for_testing();
|
| + } else {
|
| + next_rfh = wc->GetRenderManagerForTesting()->pending_frame_host();
|
| + }
|
| +
|
| + EXPECT_TRUE(next_rfh);
|
| + EXPECT_NE(shell->web_contents()->GetRenderProcessHost()->GetID(),
|
| + next_rfh->GetProcess()->GetID());
|
|
|
| - return pending_rvh;
|
| + return next_rfh->render_view_host();
|
| }
|
|
|
| } // namespace
|
|
|