Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Unified Diff: webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc

Issue 2813753002: Modified the rtp_receiver_unittests. (Closed)
Patch Set: Modified the rtp_receiver_unittests. Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
diff --git a/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc b/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
index 9dd43c416abd02112087364eb925f5600d8e4cae..6ae5f97451d6d98027e1c36d2366ca2f54bb75a8 100644
--- a/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
+++ b/webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.cc
@@ -211,12 +211,11 @@ TelephoneEventHandler* RtpReceiverImpl::GetTelephoneEventHandler() {
}
std::vector<RtpSource> RtpReceiverImpl::GetSources() const {
- int64_t now_ms = clock_->TimeInMilliseconds();
- std::vector<RtpSource> sources;
-
- {
rtc::CritScope lock(&critical_section_rtp_receiver_);
+ int64_t now_ms = clock_->TimeInMilliseconds();
+ std::vector<RtpSource> sources;
+
RTC_DCHECK(std::is_sorted(ssrc_sources_.begin(), ssrc_sources_.end(),
[](const RtpSource& lhs, const RtpSource& rhs) {
return lhs.timestamp_ms() < rhs.timestamp_ms();
@@ -244,8 +243,6 @@ std::vector<RtpSource> RtpReceiverImpl::GetSources() const {
}
sources.push_back(*rit);
}
Taylor Brandstetter 2017/04/10 22:35:14 Can remove a level of indentation now.
- } // End critsect.
-
return sources;
}

Powered by Google App Engine
This is Rietveld 408576698