Delete rtp_sender_ check in ModuleRtpRtcpImpl2::SetSendingMediaStatus

Analogous to https://webrtc-review.googlesource.com/c/src/+/267845/

Bug: webrtc:10198
Change-Id: Ib7d5e9b2a456486a419c61e7b2ce36df8960c67a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/268762
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Jakob Ivarsson‎ <jakobi@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#37550}
This commit is contained in:
Niels Möller 2022-07-18 15:01:12 +02:00 committed by WebRTC LUCI CQ
parent 03f8b8a241
commit 253f36f88e
2 changed files with 1 additions and 9 deletions

View File

@ -578,7 +578,6 @@ ChannelReceive::ChannelReceive(
InitFrameTransformerDelegate(std::move(frame_transformer));
rtp_rtcp_ = ModuleRtpRtcpImpl2::Create(configuration);
rtp_rtcp_->SetSendingMediaStatus(false);
rtp_rtcp_->SetRemoteSSRC(remote_ssrc_);
// Ensure that RTCP is enabled for the created channel.

View File

@ -286,15 +286,8 @@ bool ModuleRtpRtcpImpl2::Sending() const {
return rtcp_sender_.Sending();
}
// TODO(nisse): This method shouldn't be called for a receive-only
// stream. Delete rtp_sender_ check as soon as all applications are
// updated.
void ModuleRtpRtcpImpl2::SetSendingMediaStatus(const bool sending) {
if (rtp_sender_) {
rtp_sender_->packet_generator.SetSendingMediaStatus(sending);
} else {
RTC_DCHECK(!sending);
}
rtp_sender_->packet_generator.SetSendingMediaStatus(sending);
}
bool ModuleRtpRtcpImpl2::SendingMedia() const {