Commit d8c7381d authored by vitor's avatar vitor

Handle the case where we do not have enough input

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@13282 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent f6dd621f
......@@ -343,9 +343,11 @@ static int ra144_decode_frame(AVCodecContext * avctx,
Real144_internal *glob = avctx->priv_data;
GetBitContext gb;
if(buf_size == 0)
return 0;
if(buf_size < 20) {
av_log(avctx, AV_LOG_ERROR,
"Frame too small (%d bytes). Truncated file?\n", buf_size);
return buf_size;
}
init_get_bits(&gb, buf, 20 * 8);
for (i=0; i<10; i++)
......
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