From 460c649b5f465d5a0c601d6bfbe928aaeb0f4da2 Mon Sep 17 00:00:00 2001 From: David Schleef Date: Sun, 14 Mar 2010 13:11:53 -0700 Subject: [PATCH] oggdemux: Don't drop zero-sized packets Zero-sized packets have relevence to Theora. --- ext/ogg/gstoggdemux.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ext/ogg/gstoggdemux.c b/ext/ogg/gstoggdemux.c index 27e17d5c59..96315c04fc 100644 --- a/ext/ogg/gstoggdemux.c +++ b/ext/ogg/gstoggdemux.c @@ -609,9 +609,11 @@ gst_ogg_demux_chain_peer (GstOggPad * pad, ogg_packet * packet, } } - /* check for invalid buffer sizes */ - if (G_UNLIKELY (offset + trim >= packet->bytes)) - goto empty_packet; + if (pad->map.is_ogm_text) { + /* check for invalid buffer sizes */ + if (G_UNLIKELY (offset + trim >= packet->bytes)) + goto empty_packet; + } ret = gst_pad_alloc_buffer_and_set_caps (GST_PAD_CAST (pad),