Commit 1b8741a6 authored by Michael Niedermayer's avatar Michael Niedermayer

4xm: fix division by zero caused by bps<8

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent dae85054
......@@ -200,6 +200,11 @@ static int fourxm_read_header(AVFormatContext *s)
ret = AVERROR_INVALIDDATA;
goto fail;
}
if(!fourxm->tracks[current_track].adpcm && fourxm->tracks[current_track].bits<8){
av_log(s, AV_LOG_ERROR, "bits unspecified for non ADPCM\n");
ret = AVERROR_INVALIDDATA;
goto fail;
}
i += 8 + size;
/* allocate a new AVStream */
......
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