RtpRtcp modules and below: Make media, RTX and FEC SSRCs const
Downstream usage of SetSsrc() / SetRtxSsrc() should now be gone. Let's remove them, make the members const, and remove now unnecessary locking. Bug: webrtc:10774 Change-Id: Ie4c1b3935508cf329c5553030f740c565d32e04b Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/155660 Commit-Queue: Erik Språng <sprang@webrtc.org> Reviewed-by: Niels Moller <nisse@webrtc.org> Cr-Commit-Position: refs/heads/master@{#29475}
This commit is contained in:
@ -825,31 +825,6 @@ TEST_F(RtcpSenderTest, DoesntSchedulesInitialReportWhenSsrcSetOnConstruction) {
|
||||
EXPECT_FALSE(rtcp_sender_->TimeToSendRTCPReport(false));
|
||||
}
|
||||
|
||||
TEST_F(RtcpSenderTest, DoesntSchedulesInitialReportOnFirstSetSsrc) {
|
||||
// Set up without first SSRC not set at construction.
|
||||
RtpRtcp::Configuration configuration = GetDefaultConfig();
|
||||
configuration.local_media_ssrc = absl::nullopt;
|
||||
|
||||
rtcp_sender_.reset(new RTCPSender(configuration));
|
||||
rtcp_sender_->SetRemoteSSRC(kRemoteSsrc);
|
||||
rtcp_sender_->SetTimestampOffset(kStartRtpTimestamp);
|
||||
rtcp_sender_->SetLastRtpTime(kRtpTimestamp, clock_.TimeInMilliseconds(),
|
||||
/*payload_type=*/0);
|
||||
rtcp_sender_->SetRTCPStatus(RtcpMode::kReducedSize);
|
||||
|
||||
// Set SSRC for the first time. New report should not be scheduled.
|
||||
rtcp_sender_->SetSSRC(kSenderSsrc);
|
||||
clock_.AdvanceTimeMilliseconds(100);
|
||||
EXPECT_FALSE(rtcp_sender_->TimeToSendRTCPReport(false));
|
||||
}
|
||||
|
||||
TEST_F(RtcpSenderTest, SchedulesReportOnSsrcChange) {
|
||||
rtcp_sender_->SetRTCPStatus(RtcpMode::kReducedSize);
|
||||
rtcp_sender_->SetSSRC(kSenderSsrc + 1);
|
||||
clock_.AdvanceTimeMilliseconds(100);
|
||||
EXPECT_TRUE(rtcp_sender_->TimeToSendRTCPReport(false));
|
||||
}
|
||||
|
||||
TEST_F(RtcpSenderTest, SendsCombinedRtcpPacket) {
|
||||
rtcp_sender_->SetRTCPStatus(RtcpMode::kReducedSize);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user