diff options
author | wolfbeast <mcwerewolf@wolfbeast.com> | 2020-04-07 10:55:20 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@wolfbeast.com> | 2020-04-08 08:53:25 +0200 |
commit | 0507f298e9a5124634fb16c91b404d08356639b3 (patch) | |
tree | 33790414e7aab4c28a072cc459260a77eca16fe5 | |
parent | d9c31941e79b33b0f50345abed13925cb37f0399 (diff) | |
download | uxp-0507f298e9a5124634fb16c91b404d08356639b3.tar.gz |
[Docshell] Ensure nsDocShell::mContentViewer is released properly.
-rw-r--r-- | docshell/base/nsDocShell.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/docshell/base/nsDocShell.cpp b/docshell/base/nsDocShell.cpp index 6104ebfa71..97051ab76e 100644 --- a/docshell/base/nsDocShell.cpp +++ b/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); } |