Commit ae7f7d8d authored by michael's avatar michael

Flush the bitreservour.

Fixes issue1716


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@21559 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 2f782b80
...@@ -920,6 +920,14 @@ static int wma_decode_superframe(AVCodecContext *avctx, ...@@ -920,6 +920,14 @@ static int wma_decode_superframe(AVCodecContext *avctx,
return -1; 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 = AVCodec wmav1_decoder =
{ {
"wmav1", "wmav1",
...@@ -930,6 +938,7 @@ AVCodec wmav1_decoder = ...@@ -930,6 +938,7 @@ AVCodec wmav1_decoder =
NULL, NULL,
ff_wma_end, ff_wma_end,
wma_decode_superframe, wma_decode_superframe,
.flush=flush,
.long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 1"), .long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 1"),
}; };
...@@ -943,5 +952,6 @@ AVCodec wmav2_decoder = ...@@ -943,5 +952,6 @@ AVCodec wmav2_decoder =
NULL, NULL,
ff_wma_end, ff_wma_end,
wma_decode_superframe, wma_decode_superframe,
.flush=flush,
.long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 2"), .long_name = NULL_IF_CONFIG_SMALL("Windows Media Audio 2"),
}; };
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment