summaryrefslogtreecommitdiffstats
path: root/dom/base/nsDocument.cpp
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2020-10-24 10:42:23 +0000
committerMoonchild <moonchild@palemoon.org>2020-10-24 10:42:23 +0000
commite1db27e19989db11fef70f439cf95821316535b3 (patch)
treeabac2c9f5115323a8816d3ef600d8cb2bca5a33e /dom/base/nsDocument.cpp
parenta98d06380fe706e3b1b602411c597b9882516b3e (diff)
parenta5203631d8cded437c05243cde17cddeba13e3ec (diff)
downloadUXP-e1db27e19989db11fef70f439cf95821316535b3.tar
UXP-e1db27e19989db11fef70f439cf95821316535b3.tar.gz
UXP-e1db27e19989db11fef70f439cf95821316535b3.tar.lz
UXP-e1db27e19989db11fef70f439cf95821316535b3.tar.xz
UXP-e1db27e19989db11fef70f439cf95821316535b3.zip
Merge branch 'redwood' into releaseRELBASE_20201024RC_20201024
Diffstat (limited to 'dom/base/nsDocument.cpp')
-rw-r--r--dom/base/nsDocument.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/dom/base/nsDocument.cpp b/dom/base/nsDocument.cpp
index 0b07ef4ec..144f048eb 100644
--- a/dom/base/nsDocument.cpp
+++ b/dom/base/nsDocument.cpp
@@ -3689,6 +3689,12 @@ nsDocument::DeleteShell()
// objects for @font-face rules that came from the style set.
RebuildUserFontSet();
+ if (mResizeObserverController) {
+ // If the shell is going away, we need to remove any links to this document
+ // from the observer.
+ mResizeObserverController->DetachFromDocument();
+ }
+
nsIPresShell* oldShell = mPresShell;
mPresShell = nullptr;
UpdateFrameRequestCallbackSchedulingState(oldShell);