Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge r249954 - [First-letter] Use WeakPtr for the first-letter inser…
…tion point. https://bugs.webkit.org/show_bug.cgi?id=201842 <rdar://problem/51373788> Reviewed by Antti Koivisto. Source/WebCore: The about-to-be-removed first letter renderer's sibling could potentially be destroyed too as the result of the anonymous subtree collapsing logic (when the next sibling is a generated anonymous block and it is not needed anymore.) Test: fast/text/first-letter-with-columns-crash.html * rendering/updating/RenderTreeBuilderFirstLetter.cpp: (WebCore::RenderTreeBuilder::FirstLetter::updateStyle): LayoutTests: * fast/text/first-letter-with-columns-crash-expected.txt: Added. * fast/text/first-letter-with-columns-crash.html: Added.
- Loading branch information
1 parent
47f2f0a
commit d79c511
Showing
5 changed files
with
52 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
LayoutTests/fast/text/first-letter-with-columns-crash-expected.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
First letter -PASS if no crash. |
23 changes: 23 additions & 0 deletions
23
LayoutTests/fast/text/first-letter-with-columns-crash.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<style> | ||
:first-letter { | ||
float: right; | ||
content: url() | ||
} | ||
|
||
body { | ||
columns: 2; | ||
} | ||
</style> | ||
<body>First letter -PASS if no crash.<span id=outer><span id=inner> | ||
<script> | ||
if (window.testRunner) | ||
testRunner.dumpAsText(); | ||
outer.addEventListener("DOMSubtreeModified", function() { | ||
document.execCommand(false); | ||
document.body.style.setProperty("-webkit-columns","initial"); | ||
inner.setAttribute("foobar",""); | ||
document.body.style.setProperty("-webkit-writing-mode","vertical-lr"); | ||
|
||
}); | ||
outer.setAttribute("foobar",""); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters