sink_filter_ds.cc: add lock to Receive procedure to Pause().

BUG=2233
TEST=AUTO Test
R=wu@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/10969004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@5827 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
braveyao@webrtc.org 2014-04-02 02:14:55 +00:00
parent 19018ddb17
commit 790385fee4

View File

@ -437,6 +437,7 @@ CaptureSinkFilter::GetPin(IN int Index)
STDMETHODIMP CaptureSinkFilter::Pause()
{
LockReceive();
LockFilter();
if (m_State == State_Stopped)
{
@ -456,6 +457,7 @@ STDMETHODIMP CaptureSinkFilter::Pause()
m_State = State_Paused;
}
UnlockFilter();
UnlockReceive();
return S_OK;
}