bug 1271436 - use nsIDocShellTreeItem::GetWindow() more r=smaug
This commit is contained in:
@@ -123,8 +123,11 @@ nsGenericHTMLFrameElement::GetContentWindow()
|
||||
|
||||
nsCOMPtr<nsIDocShell> doc_shell;
|
||||
mFrameLoader->GetDocShell(getter_AddRefs(doc_shell));
|
||||
if (!doc_shell) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsPIDOMWindowOuter> win = do_GetInterface(doc_shell);
|
||||
nsCOMPtr<nsPIDOMWindowOuter> win = doc_shell->GetWindow();
|
||||
|
||||
if (!win) {
|
||||
return nullptr;
|
||||
|
||||
Reference in New Issue
Block a user