Null dereference loading Blink layout test editing/execCommand/insert-image-changing...
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Oct 2015 23:05:54 +0000 (23:05 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 26 Oct 2015 23:05:54 +0000 (23:05 +0000)
commitb73a47ee7d56552ee9f84645a360688c7ea8da92
treefab32374a564da52e6cc775250fe6c1c0694c4dd
parent1cf7157a71008dae19df99436af8a49aa972e031
Null dereference loading Blink layout test editing/execCommand/insert-image-changing-visibility-crash.html
https://bugs.webkit.org/show_bug.cgi?id=150208
<rdar://problem/23137109>

Patch by Jiewen Tan <jiewen_tan@apple.com> on 2015-10-26
Reviewed by Chris Dumez.

Source/WebCore:

This is a merge from Blink r168502:
https://codereview.chromium.org/183893018

Test: editing/execCommand/insert-image-changing-visibility-crash.html

* editing/ReplaceSelectionCommand.cpp:
(WebCore::ReplaceSelectionCommand::doApply):
We should check again the visibility of the inserted position again since
the replacement might change the visibility.

LayoutTests:

* editing/execCommand/insert-image-changing-visibility-crash-expected.txt: Added.
* editing/execCommand/insert-image-changing-visibility-crash.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@191608 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/editing/execCommand/insert-image-changing-visibility-crash-expected.txt [new file with mode: 0644]
LayoutTests/editing/execCommand/insert-image-changing-visibility-crash.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/editing/ReplaceSelectionCommand.cpp