Commit 6a16ca70 authored by vitor's avatar vitor

Fix bug when elbg->utility_inc[elbg->numCB-1] == 1


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@17926 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 21e4e1c3
......@@ -105,7 +105,7 @@ static int get_high_utility_cell(elbg_data *elbg)
{
int i=0;
/* Using linear search, do binary if it ever turns to be speed critical */
int r = av_lfg_get(elbg->rand_state)%(elbg->utility_inc[elbg->numCB-1]-1) + 1;
int r = av_lfg_get(elbg->rand_state)%elbg->utility_inc[elbg->numCB-1] + 1;
while (elbg->utility_inc[i] < r)
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