From e242d3f9fe1cbbcb14e7c9e8e68b46625b9e5cac Mon Sep 17 00:00:00 2001 From: Jonathan Watt Date: Thu, 12 May 2016 17:22:25 +0100 Subject: [PATCH] Bug 1263060, part 2 - Prevent nsFrameLoader from loading sub-documents in XBL bindings documents. r=smaug --- dom/base/nsFrameLoader.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dom/base/nsFrameLoader.cpp b/dom/base/nsFrameLoader.cpp index c3c336c098e9..9b91e938ee44 100644 --- a/dom/base/nsFrameLoader.cpp +++ b/dom/base/nsFrameLoader.cpp @@ -225,6 +225,11 @@ nsFrameLoader::LoadFrame() return NS_OK; } + if (doc->IsLoadedAsInteractiveData()) { + // XBL bindings doc shouldn't load sub-documents. + return NS_OK; + } + nsCOMPtr base_uri = mOwnerContent->GetBaseURI(); const nsAFlatCString &doc_charset = doc->GetDocumentCharacterSet(); const char *charset = doc_charset.IsEmpty() ? nullptr : doc_charset.get();