Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Issue 182533004: Fix crash in CompositeEditCommand::cloneParagraphUnderNewElement(). (Closed)

Created:
6 years, 9 months ago by Yuta Kitamura
Modified:
6 years, 9 months ago
CC:
blink-reviews
Visibility:
Public.

Description

Fix crash in CompositeEditCommand::cloneParagraphUnderNewElement(). The root cause is CompositeEditCommand::moveParagraphWithClones() passing two positions |start| and |end| which do not follow the document order, i.e. in some situations |start| is located after |end| because of the difference in affinity. This patch fixes this crash by normalizing |end| to |start| in such situations. It also adds an ASSERT that checks the relationship between |start| and |end|. BUG=345005 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=168160

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+38 lines, -7 lines) Patch
A + LayoutTests/editing/execCommand/format-block-crash.html View 1 chunk +3 lines, -3 lines 0 comments Download
A + LayoutTests/editing/execCommand/format-block-crash-expected.txt View 1 chunk +1 line, -1 line 0 comments Download
A LayoutTests/editing/execCommand/resources/format-block-crash-iframe.html View 1 chunk +29 lines, -0 lines 0 comments Download
M Source/core/editing/CompositeEditCommand.h View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/editing/CompositeEditCommand.cpp View 2 chunks +4 lines, -2 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
Yuta Kitamura
6 years, 9 months ago (2014-02-27 05:01:47 UTC) #1
yoichio
lgtm
6 years, 9 months ago (2014-02-27 05:08:31 UTC) #2
Yuta Kitamura
+Levi, can you take a look?
6 years, 9 months ago (2014-02-27 11:19:56 UTC) #3
Yuta Kitamura
Anyone from OWNERS?
6 years, 9 months ago (2014-02-28 03:30:58 UTC) #4
leviw_travelin_and_unemployed
Great! LGTM!
6 years, 9 months ago (2014-02-28 18:22:28 UTC) #5
leviw_travelin_and_unemployed
The CQ bit was checked by leviw@chromium.org
6 years, 9 months ago (2014-02-28 18:22:32 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/yutak@chromium.org/182533004/1
6 years, 9 months ago (2014-02-28 18:23:25 UTC) #7
commit-bot: I haz the power
6 years, 9 months ago (2014-02-28 19:32:37 UTC) #8
Message was sent while issue was closed.
Change committed as 168160

Powered by Google App Engine
This is Rietveld 408576698