mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1084513 - Add a null check on callingDoc before we try and get its principal. r=smaug
This commit is contained in:
parent
a936a6e6bd
commit
fe0b72ee7a
@ -305,7 +305,7 @@ XMLDocument::Load(const nsAString& aUrl, ErrorResult& aRv)
|
||||
nsCOMPtr<nsIPrincipal> principal = NodePrincipal();
|
||||
|
||||
// The callingDoc's Principal and doc's Principal should be the same
|
||||
if (callingDoc->NodePrincipal() != principal) {
|
||||
if (callingDoc && (callingDoc->NodePrincipal() != principal)) {
|
||||
nsContentUtils::ReportToConsole(nsIScriptError::errorFlag,
|
||||
NS_LITERAL_CSTRING("DOM"),
|
||||
callingDoc,
|
||||
|
Loading…
Reference in New Issue
Block a user