summaryrefslogtreecommitdiffstats
path: root/dom/base/ResizeObserverController.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'dom/base/ResizeObserverController.cpp')
-rw-r--r--dom/base/ResizeObserverController.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/dom/base/ResizeObserverController.cpp b/dom/base/ResizeObserverController.cpp
index 924bba10d..349cb66ba 100644
--- a/dom/base/ResizeObserverController.cpp
+++ b/dom/base/ResizeObserverController.cpp
@@ -59,6 +59,12 @@ ResizeObserverNotificationHelper::Register()
void
ResizeObserverNotificationHelper::Unregister()
{
+ if (!mOwner) {
+ // We've outlived our owner, so there's nothing registered anymore.
+ mRegistered = false;
+ return;
+ }
+
if (!mRegistered) {
return;
}