[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <9a1962e2-fa9f-f423-c16d-8ba529a931eb@gmail.com>
Date: Thu, 2 Sep 2021 09:41:35 -0700
From: David Ahern <dsahern@...il.com>
To: Eric Dumazet <edumazet@...gle.com>,
Tim Gardner <tim.gardner@...onical.com>
Cc: netdev <netdev@...r.kernel.org>,
"David S. Miller" <davem@...emloft.net>,
Hideaki YOSHIFUJI <yoshfuji@...ux-ipv6.org>,
David Ahern <dsahern@...nel.org>,
Jakub Kicinski <kuba@...nel.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH linux-next] ipv4: Fix NULL deference in
fnhe_remove_oldest()
On 9/2/21 9:38 AM, Eric Dumazet wrote:
> On Thu, Sep 2, 2021 at 9:32 AM Tim Gardner <tim.gardner@...onical.com> wrote:
>>
>> Coverity complains that linux-next commit 67d6d681e15b5 ("ipv4: make
>> exception cache less predictible") neglected to check for NULL before
>> dereferencing 'oldest'. It appears to be possible to fall through the for
>> loop without ever setting 'oldest'.
>
> Coverity is wrong.
>
> fnhe_remove_oldest() is only called when there are at least 6 items
> in the list.
>
> There is no way oldest could be NULL, or that oldest_p could contain garbage.
>
+1
Powered by blists - more mailing lists