Index: chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc |
diff --git a/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc b/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc |
index 6254ba8daf289d352c138e0a77a963a5b8f779e5..0628a00d9aa2db06a0f0558dd3010f24ee957cd9 100644 |
--- a/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc |
+++ b/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc |
@@ -6,7 +6,10 @@ |
#include <stddef.h> |
+#include <memory> |
#include <set> |
+#include <string> |
+#include <vector> |
#include "base/command_line.h" |
#include "base/debug/alias.h" |
@@ -684,14 +687,14 @@ ChromeContentBrowserClientExtensionsPart::GetVpnServiceProxy( |
// static |
bool ChromeContentBrowserClientExtensionsPart:: |
- ShouldFrameShareParentSiteInstanceDespiteTopDocumentIsolation( |
- const GURL& subframe_url, |
- content::SiteInstance* parent_site_instance) { |
+ IsMainFrameSiteInstanceExcludedFromTopDocumentIsolation( |
+ content::SiteInstance* main_frame_site_instance) { |
+ // Disable TDI if the main frame's SiteInstance is a hosted app. |
+ // See also https://crbug.com/679011. |
const Extension* extension = |
- ExtensionRegistry::Get(parent_site_instance->GetBrowserContext()) |
+ ExtensionRegistry::Get(main_frame_site_instance->GetBrowserContext()) |
->enabled_extensions() |
- .GetExtensionOrAppByURL(parent_site_instance->GetSiteURL()); |
- |
+ .GetExtensionOrAppByURL(main_frame_site_instance->GetSiteURL()); |
return extension && extension->is_hosted_app(); |
} |