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

pull/24/head
wolfbeast 2 years ago committed by Roy Tam
parent 4337a5f1a8
commit c8b7ac3f86
  1. 6
      docshell/base/nsDocShell.cpp

@ -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);
}

Loading…
Cancel
Save