Moving this from bug #254954. I'm not sure that changing m_player to be a WeakPtr is actually safe to do without auditing its usage further. For example, in MediaPlayerPrivateGStreamer::handleNeedContextMessage, we have: gst_structure_set(contextStructure, "player", G_TYPE_POINTER, m_player.get(), nullptr); gst_element_set_context(GST_ELEMENT(GST_MESSAGE_SRC(message)), context.get()); So now it's stored dereferenced for what I assume is the lifetime of this GstMessage, and the WeakPtr provides no protection against invalidation. So probably it's not safe to use WeakPtr. This should be looked at more closely.
Pull request: https://github.com/WebKit/WebKit/pull/15003
Committed 265236@main (1ddda51c8059): <https://commits.webkit.org/265236@main> Reviewed commits have been landed. Closing PR #15003 and removing active labels.
<rdar://problem/110891059>