DescriptionAllow lazy removal of (context) lifecycle observers while stopping.
r402141 imposed the restriction on ContextLifecycleObservers behavior
during stop() notifications of no longer being allowed to remove
observers while handling stop(). That constraint enables iteration
to be handled without allocating a snapshot of the observer set.
That restriction proves too constraining for media elements indirectly
holding onto AssociatedURLLoader objects while being stopped
(see associated bug for info.) Consequently, we allow observer removals
while keeping observer set iteration safe & allocation-free -- removals
are recorded while iterating, and removed in one go afterwards.
This is only done for notifyStoppingActiveDOMObjects(), as the other
notifications over context lifecycle observers do not require this
flexibility.
R=
BUG=623755
Committed: https://crrev.com/651bd9f00d9138c0118e9aa923b389d51bb33763
Cr-Commit-Position: refs/heads/master@{#402445}
Patch Set 1 #
Messages
Total messages: 11 (5 generated)
|