| Index: third_party/WebKit/Source/core/loader/FrameLoader.cpp
|
| diff --git a/third_party/WebKit/Source/core/loader/FrameLoader.cpp b/third_party/WebKit/Source/core/loader/FrameLoader.cpp
|
| index 12a5819756dd187cc107b9ce227baafbe2b4509e..50c8e7b3dbad8272e18c19ac1b28775bfa5620f2 100644
|
| --- a/third_party/WebKit/Source/core/loader/FrameLoader.cpp
|
| +++ b/third_party/WebKit/Source/core/loader/FrameLoader.cpp
|
| @@ -1564,10 +1564,11 @@ bool FrameLoader::shouldContinueForNavigationPolicy(
|
| if (request.url().isEmpty() || substituteData.isValid())
|
| return true;
|
|
|
| - // If we're loading content into a subframe, check against the parent's
|
| - // Content Security Policy and kill the load if that check fails, unless we
|
| - // should bypass the main world's CSP.
|
| - if (shouldCheckMainWorldContentSecurityPolicy == CheckContentSecurityPolicy) {
|
| + // If we're loading content into |m_frame| (NavigationPolicyCurrentTab), check
|
| + // against the parent's Content Security Policy and kill the load if that
|
| + // check fails, unless we should bypass the main world's CSP.
|
| + if (policy == NavigationPolicyCurrentTab &&
|
| + shouldCheckMainWorldContentSecurityPolicy == CheckContentSecurityPolicy) {
|
| Frame* parentFrame = m_frame->tree().parent();
|
| if (parentFrame) {
|
| ContentSecurityPolicy* parentPolicy =
|
|
|