Bug 1296531 - Notify MSG track listeners of removal during shutdown. r=jesup

MozReview-Commit-ID: BnWrUUvE5qk

--HG--
extra : rebase_source : d205097a8fd9e831af9ba4638b1e957224a546a9
This commit is contained in:
Andreas Pehrson 2017-02-23 11:08:57 +01:00
Родитель 8cf8c5abb7
Коммит 63142392a5
1 изменённых файлов: 13 добавлений и 0 удалений

Просмотреть файл

@ -2480,6 +2480,12 @@ MediaStream::RemoveTrackListener(MediaStreamTrackListener* aListener,
{
mStream->RemoveTrackListenerImpl(mListener, mTrackID);
}
void RunDuringShutdown() override
{
// During shutdown we still want the listener's NotifyRemoved to be
// called, since not doing that might block shutdown of other modules.
Run();
}
RefPtr<MediaStreamTrackListener> mListener;
TrackID mTrackID;
};
@ -2536,6 +2542,13 @@ MediaStream::RemoveDirectTrackListener(DirectMediaStreamTrackListener* aListener
{
mStream->RemoveDirectTrackListenerImpl(mListener, mTrackID);
}
void RunDuringShutdown() override
{
// During shutdown we still want the listener's
// NotifyDirectListenerUninstalled to be called, since not doing that
// might block shutdown of other modules.
Run();
}
RefPtr<DirectMediaStreamTrackListener> mListener;
TrackID mTrackID;
};