net: ip: ipv6_nbr: Fix uninitialized variable in ipv6_nbr

Setting it to UINT32_MAX, as it is subsequently overwritten with
MIN(oldest, something_else).

Signed-off-by: Piotr Zierhoffer <pzierhoffer@antmicro.com>
This commit is contained in:
Piotr Zierhoffer 2019-11-06 11:45:40 +01:00 committed by Ioannis Glaropoulos
parent 1df9a2e1d3
commit bb66b298e9

View file

@ -499,7 +499,7 @@ static void ipv6_nd_remove_old_stale_nbr(void)
struct net_nbr *nbr = NULL;
struct net_ipv6_nbr_data *data = NULL;
int nbr_idx = -1;
u32_t oldest;
u32_t oldest = UINT32_MAX;
int i;
k_sem_take(&nbr_lock, K_FOREVER);