Changeset 198090 in webkit
- Timestamp:
- Mar 13, 2016 6:57:17 PM (8 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r198088 r198090 1 2016-03-13 Ryosuke Niwa <rniwa@webkit.org> 2 3 REGRESSION (r190840): crash inside details element's slotNameFunction 4 https://bugs.webkit.org/show_bug.cgi?id=155388 5 6 Reviewed by Antti Koivisto. 7 8 Added a regression test. 9 10 * fast/html/details-summary-tabindex-crash-expected.txt: Added. 11 * fast/html/details-summary-tabindex-crash.html: Added. 12 1 13 2016-03-13 Dean Jackson <dino@apple.com> 2 14 -
trunk/Source/WebCore/ChangeLog
r198087 r198090 1 2016-03-13 Ryosuke Niwa <rniwa@webkit.org> 2 3 REGRESSION (r190840): crash inside details element's slotNameFunction 4 https://bugs.webkit.org/show_bug.cgi?id=155388 5 6 Reviewed by Antti Koivisto. 7 8 The bug was caused by HTMLDetailsElement::isActiveSummary calling findAssignedSlot with a summary element 9 inside the shadow tree of the detials element. Fixed it by existing early when the summary element passed 10 to isActiveSummary is not a direct child of the details element. 11 12 Test: fast/html/details-summary-tabindex-crash.html 13 14 * dom/ShadowRoot.cpp: 15 (WebCore::ShadowRoot::findAssignedSlot): Added an assertion for regression testing. 16 * dom/SlotAssignment.cpp: 17 (WebCore::SlotAssignment::findAssignedSlot): Removed the superfluous call to assignSlots added in r190840. 18 There is no need to update the slot assignments here (entires in m_slots are added or removed by 19 addSlotElementByName or removeSlotElementByName and assignSlots only updates assignedNodes in each SlotInfo 20 which is never used in this function or findFirstSlotElement. 21 * html/HTMLDetailsElement.cpp: 22 (WebCore::HTMLDetailsElement::isActiveSummary): Fixed the bug. 23 1 24 2016-03-13 Antti Koivisto <antti@apple.com> 2 25 -
trunk/Source/WebCore/dom/ShadowRoot.cpp
r195243 r198090 183 183 HTMLSlotElement* ShadowRoot::findAssignedSlot(const Node& node) 184 184 { 185 ASSERT(node.parentNode() == host()); 185 186 if (!m_slotAssignment) 186 187 return nullptr; -
trunk/Source/WebCore/dom/SlotAssignment.cpp
r194496 r198090 65 65 return nullptr; 66 66 67 if (!m_slotAssignmentsIsValid)68 assignSlots(shadowRoot);69 70 67 auto slotName = m_slotNameFunction(node); 71 68 if (!slotName) -
trunk/Source/WebCore/html/HTMLDetailsElement.cpp
r194496 r198090 104 104 return &summary == m_defaultSummary; 105 105 106 if (summary.parentNode() != this) 107 return false; 108 106 109 auto* slot = shadowRoot()->findAssignedSlot(summary); 107 110 if (!slot)
Note: See TracChangeset
for help on using the changeset viewer.