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

Unified Diff: webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h

Issue 1877253002: Replaced CriticalSectionWrapper with rtc::CriticalSection in rtp_rtcp module (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: git cl format dtmf_queue.cc Created 4 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
« no previous file with comments | « no previous file | webrtc/modules/rtp_rtcp/source/bitrate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h
diff --git a/webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h b/webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h
index fae864107f07928318598ed2c2cd618c55c180d9..6ce643496d0105179869b31fa2b1f4ea43a523d7 100644
--- a/webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h
+++ b/webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h
@@ -13,6 +13,7 @@
#include <map>
+#include "webrtc/base/criticalsection.h"
#include "webrtc/base/scoped_ptr.h"
#include "webrtc/modules/rtp_rtcp/source/rtp_receiver_strategy.h"
#include "webrtc/modules/rtp_rtcp/source/rtp_utility.h"
@@ -122,7 +123,7 @@ class RTPPayloadRegistry {
const RtpUtility::Payload* PayloadTypeToPayload(uint8_t payload_type) const;
void ResetLastReceivedPayloadTypes() {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
last_received_payload_type_ = -1;
last_received_media_payload_type_ = -1;
}
@@ -136,34 +137,34 @@ class RTPPayloadRegistry {
bool ReportMediaPayloadType(uint8_t media_payload_type);
int8_t red_payload_type() const {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
return red_payload_type_;
}
int8_t ulpfec_payload_type() const {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
return ulpfec_payload_type_;
}
int8_t last_received_payload_type() const {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
return last_received_payload_type_;
}
void set_last_received_payload_type(int8_t last_received_payload_type) {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
last_received_payload_type_ = last_received_payload_type;
}
int8_t last_received_media_payload_type() const {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
return last_received_media_payload_type_;
}
bool use_rtx_payload_mapping_on_restore() const {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
return use_rtx_payload_mapping_on_restore_;
}
void set_use_rtx_payload_mapping_on_restore(bool val) {
- CriticalSectionScoped cs(crit_sect_.get());
+ rtc::CritScope cs(&crit_sect_);
use_rtx_payload_mapping_on_restore_ = val;
}
@@ -178,7 +179,7 @@ class RTPPayloadRegistry {
bool IsRtxInternal(const RTPHeader& header) const;
- rtc::scoped_ptr<CriticalSectionWrapper> crit_sect_;
+ rtc::CriticalSection crit_sect_;
RtpUtility::PayloadTypeMap payload_type_map_;
rtc::scoped_ptr<RTPPayloadStrategy> rtp_payload_strategy_;
int8_t red_payload_type_;
« no previous file with comments | « no previous file | webrtc/modules/rtp_rtcp/source/bitrate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698