[Docshell] Ensure nsDocShell::mContentViewer is released properly.

This commit is contained in:
wolfbeast
2020-04-07 10:55:20 +02:00
committed by Roy Tam
parent 4337a5f1a8
commit c8b7ac3f86
+6
View File
@@ -860,6 +860,12 @@ nsDocShell::~nsDocShell()
shPrivate->SetRootDocShell(nullptr);
}
if (mContentViewer) {
mContentViewer->Close(nullptr);
mContentViewer->Destroy();
mContentViewer = nullptr;
}
if (--gDocShellCount == 0) {
NS_IF_RELEASE(sURIFixup);
}