diff --git a/libavformat/avidec.c b/libavformat/avidec.c index 1a9563aed4..efb5d8639e 100644 --- a/libavformat/avidec.c +++ b/libavformat/avidec.c @@ -667,7 +667,7 @@ static int avi_read_header(AVFormatContext *s) st->start_time = 0; avio_rl32(pb); /* buffer size */ avio_rl32(pb); /* quality */ - if (ast->cum_len*ast->scale/ast->rate > 3600) { + if (ast->cum_len > 3600LL * ast->rate / ast->scale) { av_log(s, AV_LOG_ERROR, "crazy start time, iam scared, giving up\n"); ast->cum_len = 0; }