Summary: | [Cocoa] Drawing the rounded system ui font into canvas causes a crash | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Myles C. Maxfield <mmaxfield> | ||||||||||||
Component: | New Bugs | Assignee: | Myles C. Maxfield <mmaxfield> | ||||||||||||
Status: | RESOLVED FIXED | ||||||||||||||
Severity: | Normal | CC: | jjorgenson, levindixon, luonan.666, mouad.debbar, webkit-bug-importer, wenson_hsieh | ||||||||||||
Priority: | P2 | Keywords: | InRadar | ||||||||||||
Version: | WebKit Nightly Build | ||||||||||||||
Hardware: | Unspecified | ||||||||||||||
OS: | Unspecified | ||||||||||||||
See Also: | https://bugs.webkit.org/show_bug.cgi?id=229633 | ||||||||||||||
Attachments: |
|
Description
Myles C. Maxfield
2021-09-11 01:56:51 PDT
Created attachment 437945 [details]
Patch
Created attachment 437972 [details]
Patch
Created attachment 437974 [details]
Patch
Created attachment 437975 [details]
Patch
Comment on attachment 437975 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=437975&action=review > Source/WebKit/Shared/Cocoa/WebCoreArgumentCodersCocoa.mm:517 > if (!fontDescriptor) > return nullptr; What do you think about using `CTFontDescriptorCreateLastResort()` here as a sort of failsafe (perhaps with an `ASSERT_NOT_REACHED` so that we're still able to catch instances where we would've otherwise failed to decode)? Comment on attachment 437975 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=437975&action=review >> Source/WebKit/Shared/Cocoa/WebCoreArgumentCodersCocoa.mm:517 >> return nullptr; > > What do you think about using `CTFontDescriptorCreateLastResort()` here as a sort of failsafe (perhaps with an `ASSERT_NOT_REACHED` so that we're still able to catch instances where we would've otherwise failed to decode)? That is a good idea! Committed r282320 (241590@main): <https://commits.webkit.org/241590@main> Reopening to attach new patch. Created attachment 438049 [details]
Fix leak
Committed r282349 (241615@main): <https://commits.webkit.org/241615@main> *** Bug 231495 has been marked as a duplicate of this bug. *** *** Bug 231686 has been marked as a duplicate of this bug. *** *** Bug 231988 has been marked as a duplicate of this bug. *** *** Bug 232043 has been marked as a duplicate of this bug. *** |