Skip to content

Commit 86bcacc

Browse files
musamaanjumaxboe
authored andcommitted
io_uring/net: correct the type of variable
The namelen is of type int. It shouldn't be made size_t which is unsigned. The signed number is needed for error checking before use. Fixes: c559780 ("io_uring/net: move receive multishot out of the generic msghdr path") Signed-off-by: Muhammad Usama Anjum <usama.anjum@collabora.com> Link: https://lore.kernel.org/r/20240301144349.2807544-1-usama.anjum@collabora.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 3fcb9d1 commit 86bcacc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

io_uring/net.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -551,7 +551,7 @@ int io_send(struct io_kiocb *req, unsigned int issue_flags)
551551

552552
static int io_recvmsg_mshot_prep(struct io_kiocb *req,
553553
struct io_async_msghdr *iomsg,
554-
size_t namelen, size_t controllen)
554+
int namelen, size_t controllen)
555555
{
556556
if ((req->flags & (REQ_F_APOLL_MULTISHOT|REQ_F_BUFFER_SELECT)) ==
557557
(REQ_F_APOLL_MULTISHOT|REQ_F_BUFFER_SELECT)) {

0 commit comments

Comments
 (0)