Bug 200981 - Get rid of m_weakThis data members now that we have a safe way to call makeWeakPtr() from various threads
Summary: Get rid of m_weakThis data members now that we have a safe way to call makeWe...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-08-21 08:51 PDT by Chris Dumez
Modified: 2019-08-21 12:52 PDT (History)
6 users (show)

See Also:


Attachments
Patch (8.90 KB, patch)
2019-08-21 08:52 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2019-08-21 08:51:59 PDT
Get rid of m_weakThis data members now that we have a safe way to call makeWeakPtr() from various threads.
Comment 1 Chris Dumez 2019-08-21 08:52:41 PDT
Created attachment 376887 [details]
Patch
Comment 2 Alex Christensen 2019-08-21 11:05:10 PDT
Comment on attachment 376887 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=376887&action=review

> Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:49
> +// Use eager initialization for the WeakPtrFactory since we call makeWeakPtr() from another thread.

I don't think these comments are necessary.
Comment 3 Chris Dumez 2019-08-21 11:10:03 PDT
(In reply to Alex Christensen from comment #2)
> Comment on attachment 376887 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=376887&action=review
> 
> > Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:49
> > +// Use eager initialization for the WeakPtrFactory since we call makeWeakPtr() from another thread.
> 
> I don't think these comments are necessary.

I personally think it is important to document why we need eager initialization here so that nobody is tempted to remove it, or so that it can be removed when it is no longer needed. I seem to remember Geoff asking for a comment as well.
Comment 4 WebKit Commit Bot 2019-08-21 12:51:05 PDT
Comment on attachment 376887 [details]
Patch

Clearing flags on attachment: 376887

Committed r248958: <https://trac.webkit.org/changeset/248958>
Comment 5 WebKit Commit Bot 2019-08-21 12:51:06 PDT
All reviewed patches have been landed.  Closing bug.
Comment 6 Radar WebKit Bug Importer 2019-08-21 12:52:18 PDT
<rdar://problem/54567696>