зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1608118 - Remove direct listeners from the source in ForwardedInputTrack when MediaInput is removed r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D60355 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
69f068dde7
Коммит
3fabc043bf
|
@ -58,6 +58,15 @@ void ForwardedInputTrack::RemoveInput(MediaInputPort* aPort) {
|
|||
TRACK_LOG(LogLevel::Debug,
|
||||
("ForwardedInputTrack %p removing input %p", this, aPort));
|
||||
MOZ_ASSERT(aPort == mInputPort);
|
||||
|
||||
for (const auto& listener : mOwnedDirectListeners) {
|
||||
MediaTrack* source = mInputPort->GetSource();
|
||||
TRACK_LOG(LogLevel::Debug,
|
||||
("ForwardedInputTrack %p removing direct listener "
|
||||
"%p. Forwarding to input track %p.",
|
||||
this, listener.get(), aPort->GetSource()));
|
||||
source->RemoveDirectListenerImpl(listener);
|
||||
}
|
||||
mInputPort = nullptr;
|
||||
ProcessedMediaTrack::RemoveInput(aPort);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче