qcap: Add DebugInfo to critical sections.

This commit is contained in:
Jan Zerebecki 2007-03-10 22:10:09 +01:00 committed by Alexandre Julliard
parent 58f37a1251
commit 614ee8314d
3 changed files with 6 additions and 0 deletions

View File

@ -105,6 +105,7 @@ IUnknown * CALLBACK QCAP_createCaptureGraphBuilder2(IUnknown *pUnkOuter,
pCapture->ref = 1;
pCapture->mygraph = NULL;
InitializeCriticalSection(&pCapture->csFilter);
pCapture->csFilter.DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": CaptureGraphImpl.csFilter");
*phr = S_OK;
ObjectRefCount(TRUE);
}
@ -160,6 +161,7 @@ fnCaptureGraphBuilder2_Release(ICaptureGraphBuilder2 * iface)
if (!ref)
{
FIXME("Release IGraphFilter or w/e\n");
This->csFilter.DebugInfo->Spare[0] = 0;
DeleteCriticalSection(&This->csFilter);
This->lpVtbl = NULL;
This->lpVtbl2 = NULL;

View File

@ -224,6 +224,7 @@ HRESULT qcap_driver_destroy(Capture *capBox)
if( capBox->fd != -1 )
close(capBox->fd);
capBox->CritSect.DebugInfo->Spare[0] = 0;
DeleteCriticalSection(&capBox->CritSect);
CoTaskMemFree(capBox);
return S_OK;
@ -789,6 +790,7 @@ Capture * qcap_driver_init( IPin *pOut, USHORT card )
/* capBox->vtbl = &defboxVtbl; */
InitializeCriticalSection( &capBox->CritSect );
capBox->CritSect.DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": Capture.CritSect");
sprintf(device, "/dev/video%i", card);
TRACE("opening %s\n", device);

View File

@ -112,6 +112,7 @@ IUnknown * WINAPI QCAP_createVFWCaptureFilter(IUnknown *pUnkOuter, HRESULT *phr)
pVfwCapture->state = State_Stopped;
pVfwCapture->init = FALSE;
InitializeCriticalSection(&pVfwCapture->csFilter);
pVfwCapture->csFilter.DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": VfwCapture.csFilter");
hr = VfwPin_Construct((IBaseFilter *)&pVfwCapture->lpVtbl,
&pVfwCapture->csFilter, &pVfwCapture->pOutputPin);
if (!SUCCEEDED(hr))
@ -208,6 +209,7 @@ static ULONG WINAPI VfwCapture_Release(IBaseFilter * iface)
IPin_Disconnect(This->pOutputPin);
}
IPin_Release(This->pOutputPin);
This->csFilter.DebugInfo->Spare[0] = 0;
DeleteCriticalSection(&This->csFilter);
This->lpVtbl = NULL;
CoTaskMemFree(This);