| Index: content/browser/loader/resource_dispatcher_host_impl.cc
|
| diff --git a/content/browser/loader/resource_dispatcher_host_impl.cc b/content/browser/loader/resource_dispatcher_host_impl.cc
|
| index a1815a42a0f59bccab9682cc4e932caf9699fc21..73b85401319d127cd13b2198835e6077efbdf66a 100644
|
| --- a/content/browser/loader/resource_dispatcher_host_impl.cc
|
| +++ b/content/browser/loader/resource_dispatcher_host_impl.cc
|
| @@ -61,6 +61,7 @@
|
| #include "content/common/appcache_interfaces.h"
|
| #include "content/common/navigation_params.h"
|
| #include "content/common/resource_messages.h"
|
| +#include "content/common/site_isolation_policy.h"
|
| #include "content/common/ssl_status_serialization.h"
|
| #include "content/common/view_messages.h"
|
| #include "content/public/browser/browser_thread.h"
|
| @@ -1386,10 +1387,11 @@ scoped_ptr<ResourceHandler> ResourceDispatcherHostImpl::CreateResourceHandler(
|
| // to drive the transfer.
|
| bool is_swappable_navigation =
|
| request_data.resource_type == RESOURCE_TYPE_MAIN_FRAME;
|
| - // If we are using --site-per-process, install it for subframes as well.
|
| + // If out-of-process iframes are possible, then all subframe requests need
|
| + // to go through the CrossSiteResourceHandler to enforce the site isolation
|
| + // policy.
|
| if (!is_swappable_navigation &&
|
| - base::CommandLine::ForCurrentProcess()->HasSwitch(
|
| - switches::kSitePerProcess)) {
|
| + SiteIsolationPolicy::AreCrossProcessFramesPossible()) {
|
| is_swappable_navigation =
|
| request_data.resource_type == RESOURCE_TYPE_SUB_FRAME;
|
| }
|
|
|