Closed Bug 1321235 Opened 4 years ago Closed 4 years ago
Can not remove a stopped media track using remove
Track on Firefox version 52 onwards
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.98 Safari/537.36 Steps to reproduce: Stop a media tracks from a MediaStream and then remove the stopped track from the MediaStream using removeTrack. use - https://jsfiddle.net/7octza05/3/ to reproduce the issue Actual results: From Firefox 52 and onwards, if the track is stopped before calling replaceTrack(), it is not removed from the MediaStream object. It is working fine on stable (v50) and beta(51). If I try to remove a track without stopping it the media capture continues to happens, eg I try to remove a video track from the mediaStream without stopping it the camera light does not turn off and capture cont Expected results: ReplaceTrack() should remove from media stream even if is is stopped
Summary: Can not remove a stopped media track using removeTrack → Can not remove a stopped media track using removeTrack on Firefox version 52 onwards
Component: Untriaged → Audio/Video: MediaStreamGraph
Product: Firefox → Core
Andreas - perhaps track cloning fallout?
Cloning was earlier. But yeah, some sort of fallout.
Assignee: nobody → pehrson
Priority: -- → P1
So turned out we didn't have a test for this. :/ Anyhow - fallout from Bug 1208316 - MediaStream.active. And thanks for reporting Prerak!
Comment on attachment 8816201 [details] Bug 1321235 - Add a mochitest. https://reviewboard.mozilla.org/r/96966/#review97216
Attachment #8816201 - Flags: review?(rjesup) → review+
Comment on attachment 8816202 [details] Bug 1321235 - Let ended MediaStreamTracks be removable. https://reviewboard.mozilla.org/r/96968/#review97218
Attachment #8816202 - Flags: review?(rjesup) → review+
Pushed by email@example.com: https://hg.mozilla.org/integration/autoland/rev/7f0eb04ee1d5 Add a mochitest. r=jesup https://hg.mozilla.org/integration/autoland/rev/eea552a9e162 Let ended MediaStreamTracks be removable. r=jesup
Andreas, Thanks for fixing it quickly. Will this is be available on Firefox 52 also, as it's there too.
Comment on attachment 8816202 [details] Bug 1321235 - Let ended MediaStreamTracks be removable. Approval Request Comment [Feature/Bug causing the regression]: Bug 1208316 [User impact if declined]: We'd regress a shipped, minor, feature which behavior is clearly speced. [Is this code covered by automated tests?]: Yes [Has the fix been verified in Nightly?]: Yes [Needs manual test from QE? If yes, steps to reproduce]: No [List of other uplifts needed for the feature/fix]: None [Is the change risky?]: No [Why is the change risky/not risky?]: It's very simple, and has automated test coverage. [String changes made/needed]: None
Attachment #8816202 - Flags: approval-mozilla-aurora?
Comment on attachment 8816202 [details] Bug 1321235 - Let ended MediaStreamTracks be removable. fix new regression in aurora52
Attachment #8816202 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
qe-verify- per Comment 14
You need to log in before you can comment on or make changes to this bug.