Skip to content

Commit

Permalink
crypto: algif_rng - remove redundant assignment to variable err
Browse files Browse the repository at this point in the history
The variable err is being initialized with a value that is never read
and it is being updated later with a new value.  The initialization is
redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
  • Loading branch information
Colin Ian King authored and herbertx committed Apr 24, 2020
1 parent 8a656a4 commit 63e05f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crypto/algif_rng.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ static int rng_recvmsg(struct socket *sock, struct msghdr *msg, size_t len,
struct sock *sk = sock->sk;
struct alg_sock *ask = alg_sk(sk);
struct rng_ctx *ctx = ask->private;
int err = -EFAULT;
int err;
int genlen = 0;
u8 result[MAXSIZE];

Expand Down

0 comments on commit 63e05f3

Please sign in to comment.