[Webkit-unassigned] [Bug 8850] cocoa bindings - crash when DOM nodes are deleted while NSTreeController+NSTableView are bound

bugzilla-daemon at opendarwin.org bugzilla-daemon at opendarwin.org
Thu May 11 21:40:29 PDT 2006


http://bugzilla.opendarwin.org/show_bug.cgi?id=8850


darin at apple.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Attachment #8247|review?                     |review-
               Flag|                            |




------- Comment #4 from darin at apple.com  2006-05-11 21:40 PDT -------
(From update of attachment 8247)
The mutableCopyWithZone: thing confuses me. These are not copyable objects. Why
is NSTreeController calling mutableCopy on an object that doesn't implement the
NSMutableCopying protocol?

Are you sure that indexOfObjectIdenticalTo: is the only other array method we
need? The reason I ask is that if we instead subclassed from NSArray instead of
NSObject, we'd get *all* the methods from the NSExtendedArray category for
free. And I think it will be binary compatible since there are no fields in
NSArray. I think that's a better solution.

Ironically, this then means that we'll be implementing the NSCopying and
NSMutableCopying protocols. But I believe NSArray will provide the copy
implementations which will actually create new arrays. So subclassing from
NSArray should fix both of these problems.

I don't see any code to remove the event listener. I suspect that by adding the
WebView itself as a listener to the DOMDocument, we could create a situation
where the entire WebView leaks. Did you test that?

We absolutely cannot have a DOM mutation event handler that's installed 100% of
the time. That will definitely cause a performance regression because it will
disable an optimization that we do in the very common case when there are no
event listeners listening to DOM mutation events.


-- 
Configure bugmail: http://bugzilla.opendarwin.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list