[webkit-changes] [WebKit/WebKit] 7337e8: Avoid taking a Ref of SOAuthorizationSession in it...
Commit Queue
noreply at github.com
Mon Aug 5 10:31:52 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 7337e801521b2c8c312d350e4997b867a3cd64b4
https://github.com/WebKit/WebKit/commit/7337e801521b2c8c312d350e4997b867a3cd64b4
Author: Pascoe <pascoe at apple.com>
Date: 2024-08-05 (Mon, 05 Aug 2024)
Changed paths:
M Source/WebKit/UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.h
M Source/WebKit/UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.mm
Log Message:
-----------
Avoid taking a Ref of SOAuthorizationSession in it's destructor
rdar://125530945
https://bugs.webkit.org/show_bug.cgi?id=274121
Reviewed by Chris Dumez.
If the window is minimized whenever the destructor of SOAuthorizationSession is called, it can
set up a notification that takes a protectedThis of SOAuthorizationSession. However this is invalid
because we are inside the destructor, making the program crash when this notification is called and
the protectedThis is used. To fix this, we avoid setting up these notifications whenever we are in
the destructor of SOAuthorizationSession.
This issue dates back to whenever this minimize work-around was added in rdar://55669065.
There have been quite a few attempts to fix this: rdar://59672418, rdar://73477045,
rdar://72375494, and rdar://65681530, but they didn't address the root issue.
* Source/WebKit/UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.h:
* Source/WebKit/UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.mm:
(WebKit::SOAuthorizationSession::~SOAuthorizationSession):
(WebKit::SOAuthorizationSession::becomeCompleted):
(WebKit::SOAuthorizationSession::dismissViewController):
Originally-landed-as: 272448.1025 at safari-7618-branch (ee9683422733). rdar://132954964
Canonical link: https://commits.webkit.org/281835@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list