diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2010-01-30 21:55:18 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2010-01-30 21:55:18 +0000 |
commit | f28f146473808fdf97501caab1249381e909cf2c (patch) | |
tree | 12daab1e8519f35ce4a1fd747e02f5a04d8bcf5f | |
parent | 1c90d2985d5f4ca5dd74459712109b7438e4c9bf (diff) | |
download | ffmpeg-streaming-f28f146473808fdf97501caab1249381e909cf2c.zip ffmpeg-streaming-f28f146473808fdf97501caab1249381e909cf2c.tar.gz |
Flush the bitreservour.
Fixes issue1716
Originally committed as revision 21559 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/wmadec.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavcodec/wmadec.c b/libavcodec/wmadec.c index 958e185..5e04e51 100644 --- a/libavcodec/wmadec.c +++ b/libavcodec/wmadec.c @@ -920,6 +920,14 @@ static int wma_decode_superframe(AVCodecContext *avctx, return -1; } +static av_cold void flush(AVCodecContext *avctx) +{ + WMACodecContext *s = avctx->priv_data; + + s->last_bitoffset= + s->last_superframe_len= 0; +} + AVCodec wmav1_decoder = { "wmav1", @@ -930,6 +938,7 @@ AVCodec wmav1_decoder = NULL, ff_wma_end, wma_decode_superframe, + .flush=flush, .long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 1"), }; @@ -943,5 +952,6 @@ AVCodec wmav2_decoder = NULL, ff_wma_end, wma_decode_superframe, + .flush=flush, .long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 2"), }; |