Skip to content

Commit

Permalink
Revert "Cherry-pick 56b164c. rdar://122444388"
Browse files Browse the repository at this point in the history
This reverts commit 1b021b8.

Identifier: 272448.543@safari-7618.1.15.11-branch
  • Loading branch information
MyahCobbs committed Feb 10, 2024
1 parent 3cb1353 commit 27352c3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ ALLOW_NEW_API_WITHOUT_GUARDS_END
ALLOW_NEW_API_WITHOUT_GUARDS_BEGIN
StdUnorderedMap<TrackID, RetainPtr<AVSampleBufferAudioRenderer>> m_audioRenderers;
ALLOW_NEW_API_WITHOUT_GUARDS_END
Ref<WebAVSampleBufferListener> m_listener;
RefPtr<WebAVSampleBufferListener> m_listener;
#if PLATFORM(IOS_FAMILY)
bool m_displayLayerWasInterrupted { false };
#endif
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,6 @@ static inline bool shouldAddContentKeyRecipients()
destroyStreamDataParser();
destroyRenderers();
clearTracks();
m_listener->invalidate();

abort();
}
Expand Down Expand Up @@ -505,6 +504,11 @@ static inline bool shouldAddContentKeyRecipients()
#endif
}

if (m_listener) {
m_listener->invalidate();
m_listener = nullptr;
}

m_audioRenderers.clear();
}

Expand Down Expand Up @@ -1245,6 +1249,7 @@ static inline bool shouldAddContentKeyRecipients()
ASSERT(!layer || !m_decompressionSession || hasSelectedVideo());

if (m_videoLayer) {
ASSERT(m_listener);
m_videoLayer->flush();
m_videoLayer->stopRequestingMediaData();
m_listener->stopObservingLayer(m_videoLayer->displayLayer());
Expand Down

0 comments on commit 27352c3

Please sign in to comment.