strmbase: Destroy base class after child class.
This commit is contained in:
parent
992f5345ed
commit
3dbcadc278
|
@ -294,7 +294,7 @@ HRESULT WINAPI BaseRendererImpl_QueryInterface(IBaseFilter* iface, REFIID riid,
|
|||
ULONG WINAPI BaseRendererImpl_Release(IBaseFilter* iface)
|
||||
{
|
||||
BaseRenderer *This = impl_from_IBaseFilter(iface);
|
||||
ULONG refCount = BaseFilterImpl_Release(iface);
|
||||
ULONG refCount = InterlockedDecrement(&This->filter.refCount);
|
||||
|
||||
if (!refCount)
|
||||
{
|
||||
|
@ -319,6 +319,7 @@ ULONG WINAPI BaseRendererImpl_Release(IBaseFilter* iface)
|
|||
CloseHandle(This->ThreadSignal);
|
||||
CloseHandle(This->RenderEvent);
|
||||
QualityControlImpl_Destroy(This->qcimpl);
|
||||
BaseFilter_Destroy(&This->filter);
|
||||
}
|
||||
return refCount;
|
||||
}
|
||||
|
|
|
@ -313,7 +313,7 @@ HRESULT WINAPI TransformFilterImpl_QueryInterface(IBaseFilter * iface, REFIID ri
|
|||
ULONG WINAPI TransformFilterImpl_Release(IBaseFilter * iface)
|
||||
{
|
||||
TransformFilter *This = impl_from_IBaseFilter(iface);
|
||||
ULONG refCount = BaseFilterImpl_Release(iface);
|
||||
ULONG refCount = InterlockedDecrement(&This->filter.refCount);
|
||||
|
||||
TRACE("(%p/%p)->() Release from %d\n", This, iface, refCount + 1);
|
||||
|
||||
|
@ -343,6 +343,7 @@ ULONG WINAPI TransformFilterImpl_Release(IBaseFilter * iface)
|
|||
FreeMediaType(&This->pmt);
|
||||
QualityControlImpl_Destroy(This->qcimpl);
|
||||
IUnknown_Release(This->seekthru_unk);
|
||||
BaseFilter_Destroy(&This->filter);
|
||||
CoTaskMemFree(This);
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue