Adding a critical section missing in r5543.
This fixes a race caught by the linux tsan bot. R=kjellander@webrtc.org Review URL: https://webrtc-codereview.appspot.com/8739004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@5551 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
a3708ecdfe
commit
9075d519a2
@ -426,7 +426,10 @@ int32_t ViEEncoder::SetEncoder(const webrtc::VideoCodec& video_codec) {
|
||||
uint16_t max_data_payload_length =
|
||||
default_rtp_rtcp_->MaxDataPayloadLength();
|
||||
|
||||
send_padding_ = video_codec.numberOfSimulcastStreams > 1;
|
||||
{
|
||||
CriticalSectionScoped cs(data_cs_.get());
|
||||
send_padding_ = video_codec.numberOfSimulcastStreams > 1;
|
||||
}
|
||||
if (vcm_.RegisterSendCodec(&video_codec, number_of_cores_,
|
||||
max_data_payload_length) != VCM_OK) {
|
||||
WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceVideo,
|
||||
|
Loading…
x
Reference in New Issue
Block a user