summaryrefslogtreecommitdiff
path: root/gst
diff options
context:
space:
mode:
authorEdward Hervey <bilboed@bilboed.com>2010-02-13 18:18:42 +0100
committerEdward Hervey <bilboed@bilboed.com>2010-02-13 18:18:42 +0100
commitfa0e3184dd2d4a0681ad5b86528ec209336cf239 (patch)
tree26ba474bb88785c7794c98db3893ec6bd2dcc250 /gst
parent817911664e02269ae3dd64cdc4b102e2f2459bce (diff)
flvdemux: Audio tags without any content are valid.
We silently ignore them instead of erroring out.
Diffstat (limited to 'gst')
-rw-r--r--gst/flv/gstflvparse.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/gst/flv/gstflvparse.c b/gst/flv/gstflvparse.c
index 1ee175240..55fd87a86 100644
--- a/gst/flv/gstflvparse.c
+++ b/gst/flv/gstflvparse.c
@@ -579,11 +579,17 @@ gst_flv_parse_tag_audio (GstFLVDemux * demux, GstBuffer * buffer)
/* Combine them */
pts |= pts_ext << 24;
- if (GST_BUFFER_SIZE (buffer) < 12) {
- GST_ERROR_OBJECT (demux, "Too small tag size");
+ /* Error out on tags with too small headers */
+ if (GST_BUFFER_SIZE (buffer) < 11) {
+ GST_ERROR_OBJECT (demux, "Too small tag size (%d)",
+ GST_BUFFER_SIZE (buffer));
return GST_FLOW_ERROR;
}
+ /* Silently skip buffers with no data */
+ if (GST_BUFFER_SIZE (buffer) == 11)
+ return GST_FLOW_OK;
+
/* Skip the stream id and go directly to the flags */
flags = GST_READ_UINT8 (data + 7);