Commit 55b37182 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

quartz: Wait for the PullPin thread to terminate.

parent e7e576d6
......@@ -541,11 +541,7 @@ static void PullPin_Thread_Stop(PullPin *This)
TRACE("(%p)->()\n", This);
EnterCriticalSection(This->pin.pCritSec);
{
CloseHandle(This->hThread);
This->hThread = NULL;
SetEvent(This->hEventStateChanged);
}
SetEvent(This->hEventStateChanged);
LeaveCriticalSection(This->pin.pCritSec);
IBaseFilter_Release(This->pin.pinInfo.pFilter);
......@@ -831,6 +827,10 @@ HRESULT WINAPI PullPin_Disconnect(IPin *iface)
}
LeaveCriticalSection(This->pin.pCritSec);
WaitForSingleObject(This->hThread, INFINITE);
CloseHandle(This->hThread);
This->hThread = NULL;
return hr;
}
......
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