WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
223016
Release assertion failures under Editor::scanSelectionForTelephoneNumbers
https://bugs.webkit.org/show_bug.cgi?id=223016
Summary
Release assertion failures under Editor::scanSelectionForTelephoneNumbers
Tim Horton
Reported
2021-03-09 22:28:33 PST
Release assertion failures under Editor::scanSelectionForTelephoneNumbers
Attachments
Patch
(4.41 KB, patch)
2021-03-09 22:28 PST
,
Tim Horton
no flags
Details
Formatted Diff
Diff
Patch
(4.45 KB, patch)
2021-03-09 22:55 PST
,
Tim Horton
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Tim Horton
Comment 1
2021-03-09 22:28:48 PST
Created
attachment 422802
[details]
Patch
Tim Horton
Comment 2
2021-03-09 22:28:50 PST
<
rdar://problem/73159921
>
Ryosuke Niwa
Comment 3
2021-03-09 22:33:59 PST
Comment on
attachment 422802
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=422802&action=review
> Source/WebCore/editing/Editor.cpp:3705 > + if (selectedRange) {
Why not put selectedRange inside here?
> Source/WebCore/editing/Editor.cpp:3710 > + extendedRange = extendSelection(*selectedRange, charactersToExtend); > + } > + > + if (extendedRange) {
Can't we just nest these if's?
Tim Horton
Comment 4
2021-03-09 22:50:12 PST
Comment on
attachment 422802
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=422802&action=review
>> Source/WebCore/editing/Editor.cpp:3705 >> + if (selectedRange) { > > Why not put selectedRange inside here?
Good point.
>> Source/WebCore/editing/Editor.cpp:3710 >> + if (extendedRange) { > > Can't we just nest these if's?
Sure, we certainly can!
Tim Horton
Comment 5
2021-03-09 22:55:44 PST
Created
attachment 422804
[details]
Patch
EWS
Comment 6
2021-03-10 00:19:13 PST
Committed
r274203
: <
https://commits.webkit.org/r274203
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 422804
[details]
.
Darin Adler
Comment 7
2021-03-10 09:51:40 PST
Better. One other thought. To my taste, the real problem here is calling two separate functions, isRange and firstRange, to get the same information. A better design would be to call firstRange and then check if it’s missing or *collapsed* instead of relying on a separate function call to preflight that information.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug