Migrate modules/video_coding to webrtc::Mutex.
Bug: webrtc:11567
Change-Id: I8023fbe7595f7ba8ae7c7db3583fc2e560ec3df2
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/178803
Commit-Queue: Markus Handell <handellm@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31644}
diff --git a/modules/video_coding/generic_decoder.cc b/modules/video_coding/generic_decoder.cc
index cfe16ed..50ecd8d 100644
--- a/modules/video_coding/generic_decoder.cc
+++ b/modules/video_coding/generic_decoder.cc
@@ -86,7 +86,7 @@
// callbacks from one call to Decode().
VCMFrameInformation* frameInfo;
{
- rtc::CritScope cs(&lock_);
+ MutexLock lock(&lock_);
frameInfo = _timestampMap.Pop(decodedImage.timestamp());
}
@@ -172,12 +172,12 @@
void VCMDecodedFrameCallback::Map(uint32_t timestamp,
VCMFrameInformation* frameInfo) {
- rtc::CritScope cs(&lock_);
+ MutexLock lock(&lock_);
_timestampMap.Add(timestamp, frameInfo);
}
int32_t VCMDecodedFrameCallback::Pop(uint32_t timestamp) {
- rtc::CritScope cs(&lock_);
+ MutexLock lock(&lock_);
if (_timestampMap.Pop(timestamp) == NULL) {
return VCM_GENERAL_ERROR;
}