RE: [PATCH][next] i40iw: fix null pointer dereference on a null wqe pointer

From: Saleem, Shiraz
Date: Wed Apr 01 2020 - 19:40:43 EST


> Subject: [PATCH][next] i40iw: fix null pointer dereference on a null wqe pointer
>
> From: Colin Ian King <colin.king@xxxxxxxxxxxxx>
>
> Currently the null check for wqe is incorrect and lets a null wqe be passed to
> set_64bit_val and this indexes into the null pointer causing a null pointer
> dereference. Fix this by fixing the null pointer check to return an error if wqe is
> null.
>
> Addresses-Coverity: ("dereference after a null check")
> Fixes: 4b34e23f4eaa ("i40iw: Report correct firmware version")
> Signed-off-by: Colin Ian King <colin.king@xxxxxxxxxxxxx>

Ugh! Yes. Thatâs a bad one. Thanks for the fix.

Acked-by: Shiraz Saleem <shiraz.saleem@xxxxxxxxx>