[Webkit-unassigned] [Bug 16923] Attr nodes with a value of "" should not have any childNodes

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Jan 19 00:55:54 PST 2008


http://bugs.webkit.org/show_bug.cgi?id=16923





------- Comment #4 from shadow2531 at gmail.com  2008-01-19 00:55 PDT -------
At <
http://trac.webkit.org/projects/webkit/browser/trunk/WebCore/dom/Attr.cpp#L118
>, I see removeChildren() and then right after that I see that a textNode is
always appended even if v is empty.

Would something like:

if (!v.isEmpty()) {
    appendChild(document()->createTextNode(v), e)
    // whatever else needs to be moved to this condition
}

fix it?

It's basically what setTextContent does at <
http://trac.webkit.org/projects/webkit/browser/trunk/WebCore/dom/Node.cpp#L1561
>.


-- 
Configure bugmail: http://bugs.webkit.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