diff --git a/pc/peer_connection.h b/pc/peer_connection.h index c0d3e47b5a..2d07893adc 100644 --- a/pc/peer_connection.h +++ b/pc/peer_connection.h @@ -512,7 +512,8 @@ class PeerConnection : public PeerConnectionInternal, rtc::scoped_refptr receiver, const std::vector& stream_ids, std::vector>* added_streams, - std::vector>* removed_streams); + std::vector>* removed_streams) + RTC_RUN_ON(signaling_thread()); // Runs the algorithm **process the removal of a remote track** specified in // the WebRTC specification. @@ -526,12 +527,14 @@ class PeerConnection : public PeerConnectionInternal, rtc::scoped_refptr> transceiver, std::vector>* remove_list, - std::vector>* removed_streams); + std::vector>* removed_streams) + RTC_RUN_ON(signaling_thread()); void RemoveRemoteStreamsIfEmpty( const std::vector>& remote_streams, - std::vector>* removed_streams); + std::vector>* removed_streams) + RTC_RUN_ON(signaling_thread()); void OnNegotiationNeeded(); @@ -1112,11 +1115,14 @@ class PeerConnection : public PeerConnectionInternal, const std::string rtcp_cname_; // Streams added via AddStream. - rtc::scoped_refptr local_streams_; + const rtc::scoped_refptr local_streams_ + RTC_GUARDED_BY(signaling_thread()); // Streams created as a result of SetRemoteDescription. - rtc::scoped_refptr remote_streams_; + const rtc::scoped_refptr remote_streams_ + RTC_GUARDED_BY(signaling_thread()); - std::vector> stream_observers_; + std::vector> stream_observers_ + RTC_GUARDED_BY(signaling_thread()); // These lists store sender info seen in local/remote descriptions. std::vector remote_audio_sender_infos_;