зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1673526 - Simplify send track recreation condition. r=bwc
Differential Revision: https://phabricator.services.mozilla.com/D98354
This commit is contained in:
Родитель
83aebe0e67
Коммит
8da798d630
|
@ -1010,9 +1010,9 @@ nsresult MediaPipelineTransmit::SetTrack(RefPtr<MediaStreamTrack> aDomTrack) {
|
|||
mSendPort = nullptr;
|
||||
}
|
||||
|
||||
if (aDomTrack && mDomTrack && !aDomTrack->Ended() && !mDomTrack->Ended() &&
|
||||
aDomTrack->Graph() != mDomTrack->Graph() && mSendTrack) {
|
||||
// Recreate the send track if the new stream resides in different MTG.
|
||||
if (aDomTrack && !aDomTrack->Ended() && mSendTrack &&
|
||||
aDomTrack->Graph() != mSendTrack->Graph()) {
|
||||
// Recreate the send track if the new stream resides in a different MTG.
|
||||
// Stopping and re-starting will result in removing and re-adding the
|
||||
// listener BUT in different threads, since tracks belong to different MTGs.
|
||||
// This can create thread races so we wait here for the stop to happen
|
||||
|
|
Загрузка…
Ссылка в новой задаче