Calling removeTrack with RTCRtpSender does not set SenderTrack to null
[WebKit-https.git] / Source / WebCore / Modules / mediastream / RTCRtpSender.cpp
index 864bb98..93db3db 100644 (file)
@@ -62,6 +62,13 @@ void RTCRtpSender::setTrackToNull()
     m_track = nullptr;
 }
 
+void RTCRtpSender::stop()
+{
+    m_trackId = { };
+    m_track = nullptr;
+    m_backend = nullptr;
+}
+
 void RTCRtpSender::setTrack(Ref<MediaStreamTrack>&& track)
 {
     ASSERT(!isStopped());