Search
SailfishOS Open Build Service
>
Projects
>
home:sledge
:
branches:nemo:devel:hw:ti:omap4:common
>
gstreamer
> 0011-baseparse-do-not-wait-for-more-data-when-draining-it.patch
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File 0011-baseparse-do-not-wait-for-more-data-when-draining-it.patch of Package gstreamer
From 2096b1022ad513f90639aa7a04445a2da8bc5363 Mon Sep 17 00:00:00 2001 From: Vincent Penquerc'h <vincent.penquerch@collabora.co.uk> Date: Wed, 20 Jun 2012 11:44:33 +0000 Subject: [PATCH 11/11] baseparse: do not wait for more data when draining, it will never come --- libs/gst/base/gstbaseparse.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/libs/gst/base/gstbaseparse.c b/libs/gst/base/gstbaseparse.c index e721ea9..69d5c6c 100644 --- a/libs/gst/base/gstbaseparse.c +++ b/libs/gst/base/gstbaseparse.c @@ -2437,6 +2437,13 @@ gst_base_parse_chain (GstPad * pad, GstBuffer * buffer) parse->priv->discont = TRUE; /* something changed least; nullify loop check */ old_min_size = 0; + } else if (parse->priv->drain) { + /* If we are draining, but the parse wants more data for the same + start position, then we will not be able to supply more now, + we're probably looking at a truncated stream. */ + GST_DEBUG_OBJECT (parse, "Draining, and not enough data to parse next"); + gst_buffer_unref (tmpbuf); + goto done; } /* skip == 0 should imply subclass set min_size to need more data; * we check this shortly */ -- 1.7.9.5