Summary: | Crash under VisibleSelection::firstRange() | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Chris Dumez <cdumez> | ||||||||||||||||
Component: | WebCore Misc. | Assignee: | Ryosuke Niwa <rniwa> | ||||||||||||||||
Status: | RESOLVED FIXED | ||||||||||||||||||
Severity: | Normal | CC: | buildbot, cdumez, commit-queue, darin, enrica, esprehn+autocc, kangil.han, koivisto, rniwa, webkit-bug-importer | ||||||||||||||||
Priority: | P2 | Keywords: | InRadar | ||||||||||||||||
Version: | WebKit Nightly Build | ||||||||||||||||||
Hardware: | Unspecified | ||||||||||||||||||
OS: | Unspecified | ||||||||||||||||||
See Also: | https://bugs.webkit.org/show_bug.cgi?id=158373 | ||||||||||||||||||
Bug Depends on: | |||||||||||||||||||
Bug Blocks: | 148695 | ||||||||||||||||||
Attachments: |
|
Description
Chris Dumez
2016-05-31 15:41:11 PDT
Created attachment 280192 [details]
Patch
Comment on attachment 280192 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=280192&action=review > Source/WebCore/editing/VisibleSelection.cpp:135 > + > + if (start.isNull() || end.isNull()) > + return nullptr; > + Actually, we should never hit this case. The problem stems from not allowing shadow root to be anchored in selection end points. Sorry, I keep forgetting to fix this bug. Will try to upload a fix tonight. Created attachment 280310 [details]
Fixes the bug
Comment on attachment 280310 [details] Fixes the bug Attachment 280310 [details] did not pass mac-ews (mac): Output: http://webkit-queues.webkit.org/results/1421696 New failing tests: editing/mac/dictionary-lookup/dictionary-lookup-input.html Created attachment 280311 [details]
Archive of layout-test-results from ews102 for mac-yosemite
The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews102 Port: mac-yosemite Platform: Mac OS X 10.10.5
Comment on attachment 280310 [details] Fixes the bug Attachment 280310 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.webkit.org/results/1421700 New failing tests: editing/mac/dictionary-lookup/dictionary-lookup-input.html Created attachment 280312 [details]
Archive of layout-test-results from ews105 for mac-yosemite-wk2
The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews105 Port: mac-yosemite-wk2 Platform: Mac OS X 10.10.5
Comment on attachment 280310 [details] Fixes the bug Attachment 280310 [details] did not pass mac-debug-ews (mac): Output: http://webkit-queues.webkit.org/results/1421714 New failing tests: accessibility/mac/text-marker-word-nav.html accessibility/mac/text-marker-paragraph-nav.html editing/mac/dictionary-lookup/dictionary-lookup-input.html Created attachment 280313 [details]
Archive of layout-test-results from ews117 for mac-yosemite
The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews117 Port: mac-yosemite Platform: Mac OS X 10.10.5
Created attachment 280319 [details]
Fixed tests
Attachment 280319 [details] did not pass style-queue:
ERROR: Source/WebCore/editing/VisiblePosition.cpp:590: Multi line control clauses should use braces. [whitespace/braces] [4]
Total errors found: 1 in 8 files
If any of these errors are false positives, please file a bug against check-webkit-style.
Created attachment 280322 [details]
More null checks
Attachment 280322 [details] did not pass style-queue:
ERROR: Source/WebCore/editing/VisiblePosition.cpp:590: Multi line control clauses should use braces. [whitespace/braces] [4]
Total errors found: 1 in 9 files
If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 280322 [details] More null checks View in context: https://bugs.webkit.org/attachment.cgi?id=280322&action=review > Source/WebCore/editing/VisibleSelection.cpp:132 > + if (start.isNull() || end.isNull()) Did you mean to keep my change in there? I thought this should not happen? (In reply to comment #15) > Comment on attachment 280322 [details] > More null checks > > View in context: > https://bugs.webkit.org/attachment.cgi?id=280322&action=review > > > Source/WebCore/editing/VisibleSelection.cpp:132 > > + if (start.isNull() || end.isNull()) > > Did you mean to keep my change in there? I thought this should not happen? Yeah, I thought this crash was only reproducible with shadow roots but it turned out this crash has been reported since 2014 so I'm adding this as a safe guard. Comment on attachment 280322 [details]
More null checks
Looks good to me.
Comment on attachment 280322 [details] More null checks Clearing flags on attachment: 280322 Committed r201667: <http://trac.webkit.org/changeset/201667> All reviewed patches have been landed. Closing bug. |