зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1663736 - Also check mSinks for explicitly removed sinks. r=jib
Differential Revision: https://phabricator.services.mozilla.com/D99463
This commit is contained in:
Родитель
1c260024db
Коммит
7a80c84f43
|
@ -267,8 +267,8 @@ class MediaStreamTrackSource : public nsISupports {
|
|||
MOZ_ASSERT(NS_IsMainThread());
|
||||
for (auto& sink : mSinks.Clone()) {
|
||||
if (!sink) {
|
||||
MOZ_ASSERT_UNREACHABLE("Sink was not explicitly removed");
|
||||
mSinks.RemoveElement(sink);
|
||||
DebugOnly<bool> removed = mSinks.RemoveElement(sink);
|
||||
MOZ_ASSERT(!removed, "Sink was not explicitly removed");
|
||||
continue;
|
||||
}
|
||||
sink->PrincipalChanged();
|
||||
|
@ -284,8 +284,8 @@ class MediaStreamTrackSource : public nsISupports {
|
|||
MOZ_ASSERT(NS_IsMainThread());
|
||||
for (auto& sink : mSinks.Clone()) {
|
||||
if (!sink) {
|
||||
MOZ_ASSERT_UNREACHABLE("Sink was not explicitly removed");
|
||||
mSinks.RemoveElement(sink);
|
||||
DebugOnly<bool> removed = mSinks.RemoveElement(sink);
|
||||
MOZ_ASSERT(!removed, "Sink was not explicitly removed");
|
||||
continue;
|
||||
}
|
||||
sink->MutedChanged(aNewState);
|
||||
|
@ -300,8 +300,8 @@ class MediaStreamTrackSource : public nsISupports {
|
|||
MOZ_ASSERT(NS_IsMainThread());
|
||||
for (auto& sink : mSinks.Clone()) {
|
||||
if (!sink) {
|
||||
MOZ_ASSERT_UNREACHABLE("Sink was not explicitly removed");
|
||||
mSinks.RemoveElement(sink);
|
||||
DebugOnly<bool> removed = mSinks.RemoveElement(sink);
|
||||
MOZ_ASSERT(!removed, "Sink was not explicitly removed");
|
||||
continue;
|
||||
}
|
||||
sink->OverrideEnded();
|
||||
|
|
Загрузка…
Ссылка в новой задаче