Bug 179224

Summary: MutationObserver callback should be kept alive as long as its observed nodes are alive
Product: WebKit Reporter: Ryosuke Niwa <rniwa>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: RESOLVED CONFIGURATION CHANGED    
Severity: Normal CC: cdumez, ggaren, Hironori.Fujii, sam, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=179234

Description Ryosuke Niwa 2017-11-02 19:18:07 PDT
We don't keep it alive because we use a weak reference in JSMutationCallback :(
Comment 1 Radar WebKit Bug Importer 2017-11-03 13:09:07 PDT
<rdar://problem/35341598>
Comment 2 Ryosuke Niwa 2018-10-02 22:43:55 PDT
This already works today because JSMutationObserverOwner::isReachableFromOpaqueRoots checks every node being observed, and JSMutationObserver::visitAdditionalChildren visits the callback.