Commit 4c4d7261 authored by Frank Galligan's avatar Frank Galligan
Browse files

Fix potential integer overflow.

ioc found a potential integer overflow in the rate control.

This is related to

Change-Id: Ib6c4acd6e964972f932fce7490592eb134f2b7ea
parent b43c27ab
......@@ -426,8 +426,8 @@ void vp9_rc_update_rate_correction_factors(VP9_COMP *cpi, int damp_var) {
// Work out a size correction factor.
if (projected_size_based_on_q > FRAME_OVERHEAD_BITS)
correction_factor = (100 * cpi->rc.projected_frame_size) /
correction_factor = (int)((100 * (int64_t)cpi->rc.projected_frame_size) /
// More heavily damped adjustment used if we have been oscillating either side
// of target.
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