Skip to content

Commit da9f058

Browse files
authored
Properly remove observer upon deconstruction (#26)
1 parent 415fbe5 commit da9f058

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pc/video_rtp_receiver.cc

+2
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ VideoRtpReceiver::~VideoRtpReceiver() {
6060
RTC_DCHECK_RUN_ON(&signaling_thread_checker_);
6161
RTC_DCHECK(stopped_);
6262
RTC_DCHECK(!media_channel_);
63+
64+
track_->UnregisterObserver(this);
6365
}
6466

6567
std::vector<std::string> VideoRtpReceiver::stream_ids() const {

0 commit comments

Comments
 (0)