winegstreamer: Use the "filesize" field 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:
parent
1bae17c29e
commit
4a4ac2730e
|
@ -823,10 +823,10 @@ static gboolean event_sink(GstPad *pad, GstObject *parent, GstEvent *event)
|
||||||
|
|
||||||
static DWORD CALLBACK push_data(LPVOID iface)
|
static DWORD CALLBACK push_data(LPVOID iface)
|
||||||
{
|
{
|
||||||
LONGLONG maxlen, curlen;
|
|
||||||
struct parser *This = iface;
|
struct parser *This = iface;
|
||||||
GstMapInfo mapping;
|
GstMapInfo mapping;
|
||||||
GstBuffer *buffer;
|
GstBuffer *buffer;
|
||||||
|
LONGLONG maxlen;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
if (!(buffer = gst_buffer_new_allocate(NULL, 16384, NULL)))
|
if (!(buffer = gst_buffer_new_allocate(NULL, 16384, NULL)))
|
||||||
|
@ -837,10 +837,7 @@ static DWORD CALLBACK push_data(LPVOID iface)
|
||||||
|
|
||||||
IBaseFilter_AddRef(&This->filter.IBaseFilter_iface);
|
IBaseFilter_AddRef(&This->filter.IBaseFilter_iface);
|
||||||
|
|
||||||
if (!This->stop)
|
maxlen = This->stop ? This->stop : This->filesize;
|
||||||
IAsyncReader_Length(This->reader, &maxlen, &curlen);
|
|
||||||
else
|
|
||||||
maxlen = This->stop;
|
|
||||||
|
|
||||||
TRACE("Starting..\n");
|
TRACE("Starting..\n");
|
||||||
for (;;) {
|
for (;;) {
|
||||||
|
|
Loading…
Reference in New Issue