Commit b752587e authored by pross's avatar pross

Use reported_size to truncate final Bink Audio frame

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@21993 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent a0a5cabc
...@@ -272,11 +272,7 @@ static int decode_frame(AVCodecContext *avctx, ...@@ -272,11 +272,7 @@ static int decode_frame(AVCodecContext *avctx,
get_bits_align32(gb); get_bits_align32(gb);
} }
*data_size = (uint8_t*)samples - (uint8_t*)data; *data_size = FFMIN(reported_size, (uint8_t*)samples - (uint8_t*)data);
if (reported_size != *data_size) {
av_log(avctx, AV_LOG_WARNING, "reported data size (%d) does not match output data size (%d)\n",
reported_size, *data_size);
}
return buf_size; return buf_size;
} }
......
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