avformat/ape: Use 64bit for final frame size

Fixes: CID1505963 Unintentional integer overflow

Sponsored-by: Sovereign Tech Fund
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 2f04cb67
......@@ -292,7 +292,7 @@ static int ape_read_header(AVFormatContext * s)
final_size -= final_size & 3;
}
if (file_size <= 0 || final_size <= 0)
final_size = ape->finalframeblocks * 8;
final_size = ape->finalframeblocks * 8LL;
ape->frames[ape->totalframes - 1].size = final_size;
for (i = 0; i < ape->totalframes; 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