[FFmpeg-cvslog] r24537 - trunk/libavformat/rtpdec_xiph.c
mstorsjo
subversion
Tue Jul 27 10:16:03 CEST 2010
Author: mstorsjo
Date: Tue Jul 27 10:16:03 2010
New Revision: 24537
Log:
rtpdec_xiph: Drop RTP packets that come in without a prior fragment start marker.
This can avoid segfaults in some cases.
Patch by Josh Allmann, joshua dot allmann at gmail
Modified:
trunk/libavformat/rtpdec_xiph.c
Modified: trunk/libavformat/rtpdec_xiph.c
==============================================================================
--- trunk/libavformat/rtpdec_xiph.c Tue Jul 27 10:03:09 2010 (r24536)
+++ trunk/libavformat/rtpdec_xiph.c Tue Jul 27 10:16:03 2010 (r24537)
@@ -172,6 +172,11 @@ static int xiph_handle_packet(AVFormatCo
av_log(ctx, AV_LOG_ERROR, "RTP timestamps don't match!\n");
return AVERROR_INVALIDDATA;
}
+ if (!data->fragment) {
+ av_log(ctx, AV_LOG_WARNING,
+ "Received packet without a start fragment; dropping.\n");
+ return AVERROR(EAGAIN);
+ }
// copy data to fragment buffer
put_buffer(data->fragment, buf, pkt_len);
More information about the ffmpeg-cvslog
mailing list