Re: [PATCH] packet: Improve exception handling in fanout_add()

From: Stephen Hemminger
Date: Sun Dec 31 2023 - 17:44:41 EST


On Sun, 31 Dec 2023 16:39:02 +0100
Markus Elfring <Markus.Elfring@xxxxxx> wrote:

> From: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx>
> Date: Sun, 31 Dec 2023 16:30:51 +0100
>
> The kfree() function was called in some cases by the fanout_add() function
> even if the passed variable contained a null pointer.
> This issue was detected by using the Coccinelle software.
>
> Thus use another label.
>
> Signed-off-by: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx>

NAK
kfree of null is perfectly fine.
There is no need for this patch.