Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(325)

Unified Diff: third_party/WebKit/Source/core/frame/LocalFrameLifecycleNotifier.cpp

Issue 2094143002: Avoid snapshotting ContextLifecycleObservers when iterating. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: msvc compile fix.. Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/frame/LocalFrameLifecycleNotifier.cpp
diff --git a/third_party/WebKit/Source/core/frame/LocalFrameLifecycleNotifier.cpp b/third_party/WebKit/Source/core/frame/LocalFrameLifecycleNotifier.cpp
index 008e09710fb17f604c1477474412aa34dc9a43fe..609ea174e8c26eca43f025765b7edce12517f3e7 100644
--- a/third_party/WebKit/Source/core/frame/LocalFrameLifecycleNotifier.cpp
+++ b/third_party/WebKit/Source/core/frame/LocalFrameLifecycleNotifier.cpp
@@ -10,8 +10,8 @@ namespace blink {
void LocalFrameLifecycleNotifier::notifyWillDetachFrameHost()
{
- TemporaryChange<IterationType> scope(m_iterating, IteratingOverAll);
- for (LocalFrameLifecycleObserver* observer : m_observers)
+ IterationScope scope(this);
+ for (LocalFrameLifecycleObserver* observer : scope.observers())
observer->willDetachFrameHost();
}

Powered by Google App Engine
This is Rietveld 408576698