Changeset 157436 in webkit
- Timestamp:
- Oct 14, 2013 5:38:10 PM (11 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r157434 r157436 1 2013-10-14 Ryosuke Niwa <rniwa@webkit.org> 2 3 Crash in WebCore::BidiResolver<WebCore::InlineIterator, WebCore::BidiRun>::createBidiRunsForLine 4 https://bugs.webkit.org/show_bug.cgi?id=122776 5 6 Reviewed by Darin Adler. 7 8 * fast/text/whitespace/whitespace-and-margin-wrap-after-list-marker-crash-expected.txt: Added. 9 * fast/text/whitespace/whitespace-and-margin-wrap-after-list-marker-crash.html: Added. 10 1 11 2013-10-14 Samuel White <samuel_white@apple.com> 2 12 -
trunk/Source/WebCore/ChangeLog
r157434 r157436 40 40 41 41 * WebCore.vcxproj/WebCoreCommon.props: 42 43 2013-10-14 Ryosuke Niwa <rniwa@webkit.org> 44 45 Crash in WebCore::BidiResolver<WebCore::InlineIterator, WebCore::BidiRun>::createBidiRunsForLine 46 https://bugs.webkit.org/show_bug.cgi?id=122776 47 48 Reviewed by Darin Adler. 49 50 Merge https://chromium.googlesource.com/chromium/blink/+/aca89bc4d984705a1f94b623dae0ab03e239a248 51 52 Fix modification of whitespace endpoints to not assume it's operating on RenderTexts 53 54 During line layout, we use midpoints to identify RenderObjects, or parts of 55 RenderObjects, that don't need InlineBoxes, usually because of collapsed whitespace. 56 57 Prior to actually creating BidiRuns (the precursor to InlineBoxes), we use 58 checkMidpoints to fix up our lineMidpointState to handle the case where we start 59 ignoring spaces in our line, but don't stop until somewhere on the following line. 60 Previously, this function assumed that the final midpoint (called an endpoint) 61 was a RenderText, but this assumption is wrong if we have a beginning midpoint 62 created by shouldSkipWhitespaceAfterStartObject (which handles inlines and list 63 markers) and no endpoint on that line. In that case, we'd instead adjust the 64 position backwards on the beginning midpoint, which would cause us to fail to 65 create an InlineBox for the inline or list marker. In the new test added, this 66 would actually trigger a crash due to an assumption when visually re-ordering 67 BidiRuns that a non-empty line would actually contain at least one such run. 68 69 Test: fast/text/whitespace/whitespace-and-margin-wrap-after-list-marker-crash.html 70 71 * rendering/RenderBlockLineLayout.cpp: 72 (WebCore::checkMidpoints): 42 73 43 74 2013-10-14 Ryosuke Niwa <rniwa@webkit.org> -
trunk/Source/WebCore/rendering/RenderBlockLineLayout.cpp
r157391 r157436 208 208 // We hit the line break before the start point. Shave off the start point. 209 209 lineMidpointState.numMidpoints--; 210 if (endpoint.m_obj->style()->collapseWhiteSpace() )210 if (endpoint.m_obj->style()->collapseWhiteSpace() && endpoint.m_obj->isText()) 211 211 endpoint.m_pos--; 212 212 }
Note: See TracChangeset
for help on using the changeset viewer.