Changeset 192433 in webkit
- Timestamp:
- Nov 13, 2015 10:36:31 AM (8 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r192432 r192433 1 2015-11-13 Jiewen Tan <jiewen_tan@apple.com> 2 3 Element::focus() should acquire the ownership of Frame. 4 https://bugs.webkit.org/show_bug.cgi?id=150204 5 <rdar://problem/23136794> 6 7 Reviewed by Brent Fulgham. 8 9 * editing/selection/focus-iframe-removal-crash-expected.txt: Added. 10 * editing/selection/focus-iframe-removal-crash.html: Added. 11 1 12 2015-11-13 Tim Horton <timothy_horton@apple.com> 2 13 -
trunk/Source/WebCore/ChangeLog
r192414 r192433 1 2015-11-13 Jiewen Tan <jiewen_tan@apple.com> 2 3 Element::focus() should acquire the ownership of Frame. 4 https://bugs.webkit.org/show_bug.cgi?id=150204 5 <rdar://problem/23136794> 6 7 Reviewed by Brent Fulgham. 8 9 The FrameSelection::setSelection method sometimes releases the last reference to a frame. 10 When this happens, the Element::updateFocusAppearance would attempt to use dereferenced memory. 11 Instead, we should ensure that the Frame lifetime is guaranteed to extend through the duration 12 of the method call. 13 14 Test: editing/selection/focus-iframe-removal-crash.html 15 16 * dom/Element.cpp: 17 (WebCore::Element::updateFocusAppearance): 18 1 19 2015-11-13 Sergio Villar Senin <svillar@igalia.com> 2 20 -
trunk/Source/WebCore/dom/Element.cpp
r192354 r192433 2253 2253 { 2254 2254 if (isRootEditableElement()) { 2255 Frame* frame = document().frame(); 2255 // Keep frame alive in this method, since setSelection() may release the last reference to |frame|. 2256 RefPtr<Frame> frame = document().frame(); 2256 2257 if (!frame) 2257 2258 return;
Note: See TracChangeset
for help on using the changeset viewer.