| Index: Source/core/frame/LocalDOMWindow.cpp
|
| diff --git a/Source/core/frame/LocalDOMWindow.cpp b/Source/core/frame/LocalDOMWindow.cpp
|
| index 1647bbce07589501da31460c93a7b04279974b9c..ff583a6130909c5aaa981f80392cf7c201744f30 100644
|
| --- a/Source/core/frame/LocalDOMWindow.cpp
|
| +++ b/Source/core/frame/LocalDOMWindow.cpp
|
| @@ -144,6 +144,12 @@ void LocalDOMWindow::WindowFrameObserver::willDetachFrameHost()
|
| m_window->willDetachFrameHost();
|
| }
|
|
|
| +void LocalDOMWindow::WindowFrameObserver::frameDestroyed()
|
| +{
|
| + m_window->frameDestroyed();
|
| + FrameDestructionObserver::frameDestroyed();
|
| +}
|
| +
|
| class PostMessageTimer final : public NoBaseWillBeGarbageCollectedFinalized<PostMessageTimer>, public SuspendableTimer {
|
| WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(PostMessageTimer);
|
| public:
|
| @@ -594,6 +600,12 @@ void LocalDOMWindow::willDetachFrameHost()
|
| LocalDOMWindow::notifyContextDestroyed();
|
| }
|
|
|
| +void LocalDOMWindow::frameDestroyed()
|
| +{
|
| + willDestroyDocumentInFrame();
|
| + m_properties.clear();
|
| +}
|
| +
|
| void LocalDOMWindow::willDestroyDocumentInFrame()
|
| {
|
| for (const auto& domWindowProperty : m_properties)
|
| @@ -618,8 +630,7 @@ void LocalDOMWindow::unregisterProperty(DOMWindowProperty* property)
|
|
|
| void LocalDOMWindow::reset()
|
| {
|
| - willDestroyDocumentInFrame();
|
| - m_properties.clear();
|
| + frameDestroyed();
|
|
|
| m_screen = nullptr;
|
| m_history = nullptr;
|
|
|