[Webkit-unassigned] [Bug 62737] attribute parsing manipulates document structure without knowing node insertedIntoDocument

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Jan 8 21:49:03 PST 2012


https://bugs.webkit.org/show_bug.cgi?id=62737





--- Comment #5 from Darin Adler <darin at apple.com>  2012-01-08 21:49:02 PST ---
(In reply to comment #1)
> These testcases are specific to HTMLBodyElement, but i think this problem can be in any element which manipulates document()->something inside parseMappedAttribute.

Those should be very rare. I think this is a body-element-specific thing. That code assumes that the element is “the” body element for a document, but it’s really just “a” body element and not even in the document’s tree.

Other elements would typically not do that sort of thing.

I think the title of this bug is not really good. The function insertedIntoDocument isn’t really the point. The point is that a body element is modifying the document, assuming it’s the body element of that document. An inDocument check might be sufficient, we also might want to simply check if this == document()->body().

The question that could drive that decision is whether we can end up with multiple HTMLBodyElement objects in the DOM tree at once, and if so, what is the correct behavior.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list