Re: [PATCH][next] futex: fix assigned ret variable that is never read

From: André Almeida
Date: Wed Sep 01 2021 - 14:26:48 EST


Hi Colin,

Às 10:18 de 18/08/21, Colin King escreveu:
> From: Colin Ian King <colin.king@xxxxxxxxxxxxx>
>
> Currently the check on the rt_waiter and top_waiter->pi_state is
> assigning an error return code to ret but this later gets re-assigned,
> hence the check is currently ineffective. I believe the original
> intent was to return -EINVAL rather than assign it to ret. Fix this.
>
> Addresses-Coverity: ("Unused value")
> Fixes: dc7109aaa233 ("futex: Validate waiter correctly in futex_proxy_trylock_atomic()")
> Signed-off-by: Colin Ian King <colin.king@xxxxxxxxxxxxx>> ---

Reviewed-by: André Almeida <andrealmeid@xxxxxxxxxxxxx>