lavc/h264_levels: Avoid integer overflow in bitrate

Fixes CID #1439656.
pull/299/head
Mark Thompson 7 years ago
parent dc58e33dd3
commit 581b4125aa
  1. 2
      libavcodec/h264_levels.c

@ -105,7 +105,7 @@ const H264LevelDescriptor *ff_h264_guess_level(int profile_idc,
if (level->constraint_set3_flag && no_cs3f)
continue;
if (bitrate > level->max_br * h264_get_br_factor(profile_idc))
if (bitrate > (int64_t)level->max_br * h264_get_br_factor(profile_idc))
continue;
if (width_mbs * height_mbs > level->max_fs)

Loading…
Cancel
Save