aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/adpcm.c
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2016-05-19 16:40:07 +0200
committerPaul B Mahol <onemda@gmail.com>2016-05-19 23:48:25 +0200
commit14992421df88514e64fb56cfa888eade918cfc19 (patch)
treeb013e45cbcb3268be932f9a181d84b17b5a3084a /libavcodec/adpcm.c
parent699201ac0ef64baee261bc6fc587d00724f195af (diff)
downloadffmpeg-14992421df88514e64fb56cfa888eade918cfc19.tar.gz
avcodec/adpcm: pick correct step_index for IMA AMV
Fixes #5538 Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavcodec/adpcm.c')
-rw-r--r--libavcodec/adpcm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/adpcm.c b/libavcodec/adpcm.c
index 0b6b92e8dc..ac74318d90 100644
--- a/libavcodec/adpcm.c
+++ b/libavcodec/adpcm.c
@@ -1310,8 +1310,8 @@ static int adpcm_decode_frame(AVCodecContext *avctx, void *data,
break;
case AV_CODEC_ID_ADPCM_IMA_AMV:
c->status[0].predictor = sign_extend(bytestream2_get_le16u(&gb), 16);
- c->status[0].step_index = bytestream2_get_le16u(&gb);
- bytestream2_skipu(&gb, 4);
+ c->status[0].step_index = bytestream2_get_byteu(&gb);
+ bytestream2_skipu(&gb, 5);
if (c->status[0].step_index > 88u) {
av_log(avctx, AV_LOG_ERROR, "ERROR: step_index = %i\n",
c->status[0].step_index);