Chromium Code Reviews| Index: content/child/web_url_loader_impl.cc |
| diff --git a/content/child/web_url_loader_impl.cc b/content/child/web_url_loader_impl.cc |
| index eb948a9508c8a2a4347f8e2ed1e218b82fa6dfb1..26437e7f5a0b4bf2eea4051f199bd2265e2613a0 100644 |
| --- a/content/child/web_url_loader_impl.cc |
| +++ b/content/child/web_url_loader_impl.cc |
| @@ -928,9 +928,14 @@ bool WebURLLoaderImpl::Context::CanHandleDataURLRequestLocally() const { |
| // For compatibility reasons on Android we need to expose top-level data:// |
| // to the browser. In tests resource_dispatcher_ can be null, and test pages |
| // need to be loaded locally. |
| + // For PlzNavigate, only send renderer-initiated requests to the browser. |
| if (resource_dispatcher_ && |
| - request_.getFrameType() == WebURLRequest::FrameTypeTopLevel) |
| - return false; |
| + request_.getFrameType() == WebURLRequest::FrameTypeTopLevel) { |
| + if (!IsBrowserSideNavigationEnabled() || |
| + request_.checkForBrowserSideNavigation()) { |
|
clamy
2017/03/06 14:41:06
Can we really get there with request_.checkForBrow
jam
2017/03/06 16:07:07
Ah, I had added that second part of the condition
|
| + return false; |
| + } |
| + } |
| #endif |
| if (request_.getFrameType() != WebURLRequest::FrameTypeTopLevel && |