[Webkit-unassigned] [Bug 91228] imagemap without a "name" attribute doesn't work (affects xkcd.com)

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jul 15 02:19:38 PDT 2013


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





--- Comment #31 from Chen Zhixiang <chenzx at cn.fujitsu.com>  2013-07-15 02:20:40 PST ---
Fix:

 Node::InsertionNotificationRequest HTMLMapElement::insertedInto(ContainerNode* insertionPoint)
 {
-    if (insertionPoint->inDocument())
-        treeScope()->addImageMap(this);
+    if (insertionPoint->inDocument()) {
+        updateCachedValue(m_cachedId, document()->isHTMLDocument() ? getIdAttribute().lower() : getIdAttribute(), treeScope(), this);
+        updateCachedValue(m_cachedName, document()->isHTMLDocument() ? fastGetAttribute(nameAttr).lower() : fastGetAttribute(nameAttr), treeScope(), this);
+    }
     return HTMLElement::insertedInto(insertionPoint);
 }

When do match in ignoring case mode, the "Id" attribute also need to be lower()'ed.
In fact, better use equalsIgnoringCase...

This fixs http://car.driver.jp/ , :-)

-- 
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