[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b137f4c6-9cbd-456d-b839-bc77d6ef9079@kernel.org>
Date: Thu, 17 Apr 2025 22:03:51 -0700
From: David Ahern <dsahern@...nel.org>
To: Kuniyuki Iwashima <kuniyu@...zon.com>, purvayeshi550@...il.com
Cc: davem@...emloft.net, edumazet@...gle.com, horms@...nel.org,
kuba@...nel.org, linux-kernel@...r.kernel.org, netdev@...r.kernel.org,
pabeni@...hat.com
Subject: Re: [PATCH] net: ipv4: Fix uninitialized pointer warning in
fnhe_remove_oldest
On 4/17/25 4:00 PM, Kuniyuki Iwashima wrote:
> From: Purva Yeshi <purvayeshi550@...il.com>
> Date: Thu, 17 Apr 2025 15:11:26 +0530
>> Fix Smatch-detected issue:
>> net/ipv4/route.c:605 fnhe_remove_oldest() error:
>> uninitialized symbol 'oldest_p'.
>>
>> Initialize oldest_p to NULL to avoid uninitialized pointer warning in
>> fnhe_remove_oldest.
>
> How does it remain uninitialised ?
>
> update_or_create_fnhe() ensures the bucket is not empty before
> calling fnhe_remove_oldest().
>
agreed. Not the simplest logic, but I do not see how oldest_p can be
unset after the loop.
Powered by blists - more mailing lists