ipa: raspberrypi: fix access to uninitialized variables
Set span_r and span_b to -1 so that when they are passed to Pwl::Eval() they won't cause access to uninitialized memory. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@iki.fi> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: David Plowman <david.plowman@raspberrypi.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
parent
5f1f3092a1
commit
5fbda0dfda
1 changed files with 1 additions and 1 deletions
|
@ -430,7 +430,7 @@ double Awb::coarseSearch(Pwl const &prior)
|
|||
|
||||
void Awb::fineSearch(double &t, double &r, double &b, Pwl const &prior)
|
||||
{
|
||||
int span_r, span_b;
|
||||
int span_r = -1, span_b = -1;
|
||||
config_.ct_r.Eval(t, &span_r);
|
||||
config_.ct_b.Eval(t, &span_b);
|
||||
double step = t / 10 * config_.coarse_step * 0.1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue