Commit 1fead73d authored by Justin Ruggles's avatar Justin Ruggles

atrac3: return error if packet is too small

parent 7e4881a2
......@@ -834,8 +834,7 @@ static int atrac3_decode_frame(AVCodecContext *avctx,
if (buf_size < avctx->block_align) {
av_log(avctx, AV_LOG_ERROR,
"Frame too small (%d bytes). Truncated file?\n", buf_size);
*data_size = 0;
return buf_size;
return AVERROR_INVALIDDATA;
}
out_size = 1024 * q->channels * av_get_bytes_per_sample(avctx->sample_fmt);
......
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