Commit 83bcd8fb authored by Adrien Béraud's avatar Adrien Béraud

sipvoiplink: fix keyframe request lock

Change-Id: I514943409a319b3d7749d05e6a3ff41c4f598c24
parent 5c5f9ed5
......@@ -747,10 +747,10 @@ SIPVoIPLink::enqueueKeyframeRequest(const std::string &id)
void
SIPVoIPLink::dequeKeyframeRequests()
{
std::lock_guard<std::mutex> lock(keyframeRequestsMutex_);
int max_requests = 20;
while (not keyframeRequests_.empty() and max_requests--) {
std::lock_guard<std::mutex> lock(keyframeRequestsMutex_);
const std::string &id(keyframeRequests_.front());
requestKeyframe(id);
keyframeRequests_.pop();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment