summaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2007-01-29 14:54:55 +0000
committerMichael Niedermayer <michaelni@gmx.at>2007-01-29 14:54:55 +0000
commitf8f0a0bdfde0c0502c2b14febaeb81972520352c (patch)
tree2fb2e745ee13705e9a812e51b50ca3b4ddcb005e /libavformat
parentb024824bed68de5c1c5162c042e2607e0d37ab57 (diff)
downloadffmpeg-streaming-f8f0a0bdfde0c0502c2b14febaeb81972520352c.zip
ffmpeg-streaming-f8f0a0bdfde0c0502c2b14febaeb81972520352c.tar.gz
fix seeking in wma
Originally committed as revision 7759 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/asf.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/asf.c b/libavformat/asf.c
index dce7233..4394328 100644
--- a/libavformat/asf.c
+++ b/libavformat/asf.c
@@ -673,7 +673,8 @@ static int asf_read_packet(AVFormatContext *s, AVPacket *pkt)
asf->packet_multi_size -= asf->packet_obj_size;
//printf("COMPRESS size %d %d %d ms:%d\n", asf->packet_obj_size, asf->packet_frag_timestamp, asf->packet_size_left, asf->packet_multi_size);
}
- if (asf_st->pkt.size != asf->packet_obj_size) { //FIXME is this condition sufficient?
+ if ( asf_st->pkt.size != asf->packet_obj_size
+ || asf_st->frag_offset + asf->packet_frag_size > asf_st->pkt.size) { //FIXME is this condition sufficient?
if(asf_st->pkt.data){
av_log(s, AV_LOG_INFO, "freeing incomplete packet size %d, new %d\n", asf_st->pkt.size, asf->packet_obj_size);
asf_st->frag_offset = 0;
OpenPOWER on IntegriCloud