Re: [PATCH] staging:gpib: Fix a dereference before null check issue

From: Dan Carpenter
Date: Wed Nov 20 2024 - 12:04:21 EST


On Wed, Nov 20, 2024 at 03:46:53PM +0100, Paolo Perego wrote:
> This commit fixes a dereference before null check issue discovered by
> Coverity (CID 1601566).
>
> The check ad line 1450 suggests that a_priv can be NULL, however it has
> been derefenced before, in the interface_to_usbdev() call.
>
> Signed-off-by: Paolo Perego <pperego@xxxxxxx>
> ---

You need a Fixes tag. But I'm pretty sure the correct fix is to remove the NULL
check.

regards,
dan carpenter