commit | 51717d15acdfb3fd538e1257331d4074234391b2 | [log] [tgz] |
---|---|---|
author | Avi Drissman <avi@chromium.org> | Tue Jun 25 19:14:32 2019 |
committer | Commit Bot <commit-bot@chromium.org> | Tue Jun 25 19:14:32 2019 |
tree | 4614fc4b86713df1d3f9ffb1bb260d2c3516ef0e | |
parent | 9f1852b44c9981e5fc473021f0c33d1837ca4150 [diff] |
Do not call -[NSView inputContext] in a dealloc. -[NSView inputContext] will create an input context if one does not exist. -[NSTextInputContext initWithClient:] takes a weak reference to the view. Pre-Catalina, that weak reference was just a raw pointer; in Catalina, that weak reference is an actual __weak reference, accessed with objc_storeWeak() et al. Pre-Catalina, a call to -[NSView inputContext] in a dealloc impl that ends up trying to create an input context just ends up taking the raw pointer reference; not the best idea, but not the end of the world. With Catalina, doing so involves trying to create a weak reference to a dying object, which makes the ObjC runtime incredibly unhappy. This is a sanity check that is breaking the code; remove it. BUG=977918 TEST=as in bug Change-Id: Ic3d242117c3c5ada0852e4a77296a507b0fccfdc Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1676424 Reviewed-by: Robert Sesek <rsesek@chromium.org> Reviewed-by: Elly Fong-Jones <ellyjones@chromium.org> Auto-Submit: Avi Drissman <avi@chromium.org> Commit-Queue: Avi Drissman <avi@chromium.org> Cr-Commit-Position: refs/heads/master@{#672187}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .