From 4ff0d1fe525b9aa612464c37dc7e2ae6ef5e9fac Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Mon, 26 Jan 2009 09:57:26 +0100 Subject: [PATCH] Drop packets with an invalid replicated data length Drop packets with an invalid replicated data length instead of continuing with an invalid timestamp and uninitialized payload metadata. All other code assumes that the timestamps are valid. --- gst/asfdemux/asfpacket.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gst/asfdemux/asfpacket.c b/gst/asfdemux/asfpacket.c index fcccf3f1a3..077d7442b7 100644 --- a/gst/asfdemux/asfpacket.c +++ b/gst/asfdemux/asfpacket.c @@ -317,6 +317,9 @@ gst_asf_demux_parse_payload (GstASFDemux * demux, AsfPacket * packet, GST_TIME_ARGS (payload.duration)); } else if (payload.rep_data_len != 0) { GST_WARNING_OBJECT (demux, "invalid replicated data length, very bad"); + *p_data += payload_len; + *p_size -= payload_len; + return FALSE; } GST_LOG_OBJECT (demux, "media object offset : %u", payload.mo_offset);