winegstreamer: Hold a reference to the filter in push_data().

Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2017-12-19 20:49:20 -06:00 committed by Alexandre Julliard
parent 83c806ed0e
commit 079d63e66c
1 changed files with 5 additions and 0 deletions

View File

@ -510,6 +510,8 @@ static DWORD CALLBACK push_data(LPVOID iface)
DWORD_PTR user;
HRESULT hr;
IBaseFilter_AddRef(&This->filter.IBaseFilter_iface);
if (!This->stop)
IAsyncReader_Length(This->pInputPin.pReader, &maxlen, &curlen);
else
@ -589,6 +591,9 @@ static DWORD CALLBACK push_data(LPVOID iface)
} while (buf);
TRACE("Stopping.. %08x\n", hr);
IBaseFilter_Release(&This->filter.IBaseFilter_iface);
return 0;
}