Changeset 271467 in webkit
- Timestamp:
- Jan 13, 2021, 3:19:23 PM (6 years ago)
- Location:
- trunk/Source/WebKit
- Files:
-
- 2 edited
-
ChangeLog (modified) (1 diff)
-
UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit/ChangeLog
r271459 r271467 1 2021-01-13 Jiewen Tan <jiewen_tan@apple.com> 2 3 Crash at SOAuthorizationSession::dismissViewController 4 https://bugs.webkit.org/show_bug.cgi?id=220482 5 <rdar://problem/72375494> 6 7 Reviewed by Darin Adler. 8 9 A crash report suggests that SOAuthorizationSession::dismissViewController could crash at evaluating m_page. 10 This could only happen if the SOAuthorizationSession object is freed. The stack trace starts with callbacks 11 from NSNotificationCenter, which capture a RefPtr of the SOAuthorizationSession object and should guarantee 12 the lifetime of the object. So it contradicts the crash report. 13 14 One of the possible explanations is that the RefPtr is somehow over-released within NSNotificationCenter since 15 it's not thread-safe. To fix that, the RefPtr can be made thread-safe. 16 17 No tests. 18 19 * UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.mm: 20 (WebKit::SOAuthorizationSession::dismissViewController): 21 1 22 2021-01-13 Wenson Hsieh <wenson_hsieh@apple.com> 2 23 -
trunk/Source/WebKit/UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.h
r255862 r271467 30 30 #include <pal/spi/cocoa/AppSSOSPI.h> 31 31 #include <wtf/Forward.h> 32 #include <wtf/RefCounted.h>33 32 #include <wtf/RetainPtr.h> 33 #include <wtf/ThreadSafeRefCounted.h> 34 34 #include <wtf/WeakObjCPtr.h> 35 35 #include <wtf/WeakPtr.h> … … 52 52 53 53 // A session will only be executed once. 54 class SOAuthorizationSession : public RefCounted<SOAuthorizationSession>, public CanMakeWeakPtr<SOAuthorizationSession> {54 class SOAuthorizationSession : public ThreadSafeRefCounted<SOAuthorizationSession, WTF::DestructionThread::MainRunLoop>, public CanMakeWeakPtr<SOAuthorizationSession> { 55 55 public: 56 56 enum class InitiatingAction : uint8_t {
Note:
See TracChangeset
for help on using the changeset viewer.