Skip to contentSkip to conversation

crypto: algif - signedness bug in skcipher_recvmsg_async()

PATCH New Dan Carpenter 1 participant 1 message Mar 26, 2015

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 crypto: algif - signedness bug in skcipher_recvmsg_async()

This needs to be signed because af_alg_make_sg() returns negative error codes.

Fixes a596999b7ddf ('crypto: algif - change algif_skcipher to be asynchronous')
crypto/algif_skcipher.c +1 -1
index 506eb5f..142430f 100644
@@ -537,7 +537,7 @@ static int skcipher_recvmsg_async(struct socket *sock, struct msghdr *msg,
 
 	while (iov_iter_count(&msg->msg_iter)) {
 		struct skcipher_async_rsgl *rsgl;
-		unsigned long used;
+		long used;
 
 		if (!ctx->used) {
 			err = skcipher_wait_for_data(sk, flags);