| Summary: | Crash from CompositeEditCommand::moveParagraphs() using Position instead of VisiblePosition | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Julian Gonzalez <julian_a_gonzalez> | ||||||
| Component: | HTML Editing | Assignee: | Nobody <webkit-unassigned> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | ews-watchlist, mifenton, rniwa, wenson_hsieh | ||||||
| Priority: | P2 | Keywords: | InRadar | ||||||
| Version: | WebKit Nightly Build | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Attachments: |
|
||||||||
|
Description
Julian Gonzalez
2021-01-25 15:22:18 PST
Created attachment 418346 [details]
Patch
Test failures here look legitimate (though I can't reproduce them locally). I'll keep working on this. Comment on attachment 418346 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=418346&action=review > LayoutTests/editing/inserting/paragraph-outdent-animationframe-crash.html:20 > + document.execCommand("selectAll", false); > + window.requestAnimationFrame(dooutdent); I think the test failure comes from this code running after this test had finished running. You need to add testRunner.waitUntilDone where you call dumpAsText, and call testRunner.notifyDone when the test is done running perhaps at the end of dooutdent? Be sure to verify that the crash still reproduces without the fix if you made those changes to the test. (In reply to Ryosuke Niwa from comment #3) > Comment on attachment 418346 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=418346&action=review > > > LayoutTests/editing/inserting/paragraph-outdent-animationframe-crash.html:20 > > + document.execCommand("selectAll", false); > > + window.requestAnimationFrame(dooutdent); > > I think the test failure comes from this code running after this test had > finished running. > You need to add testRunner.waitUntilDone where you call dumpAsText, > and call testRunner.notifyDone when the test is done running perhaps at the > end of dooutdent? > Be sure to verify that the crash still reproduces without the fix if you > made those changes to the test. This ended up being a little more complicated, but Ryosuke figured it out. Thanks to him for cleaning the test up! Created attachment 418602 [details]
Patch
Comment on attachment 418602 [details]
Patch
Looks good.
Committed r272008: <https://trac.webkit.org/changeset/272008> All reviewed patches have been landed. Closing bug and clearing flags on attachment 418602 [details]. |