diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-02-12 16:36:04 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-02-12 16:36:15 +0100 |
commit | 3e8b17f05b916087755e79545e63d92ae6323a05 (patch) | |
tree | d1b9d75769a1fbc2127c08850f9c7c8bd7dffe71 /libavformat | |
parent | f73901f815d0c6e1e9dbe6d8541e43d633b06d63 (diff) | |
parent | f5d92d9cab07429b084c88262d9af1735ac8914a (diff) | |
download | ffmpeg-3e8b17f05b916087755e79545e63d92ae6323a05.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
asfdec: fix seeking with fragmented packets
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/asfdec.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavformat/asfdec.c b/libavformat/asfdec.c index 4db908d3d9..b5400b5f87 100644 --- a/libavformat/asfdec.c +++ b/libavformat/asfdec.c @@ -1159,6 +1159,16 @@ static int asf_parse_packet(AVFormatContext *s, AVIOContext *pb, AVPacket *pkt) asf_st = asf->asf_st; av_assert0(asf_st); + if (!asf_st->frag_offset && asf->packet_frag_offset) { + av_dlog(s, "skipping asf data pkt with fragment offset for " + "stream:%d, expected:%d but got %d from pkt)\n", + asf->stream_index, asf_st->frag_offset, + asf->packet_frag_offset); + avio_skip(pb, asf->packet_frag_size); + asf->packet_size_left -= asf->packet_frag_size; + continue; + } + if (asf->packet_replic_size == 1) { // frag_offset is here used as the beginning timestamp asf->packet_frag_timestamp = asf->packet_time_start; |