mirror of
https://github.com/torvalds/linux.git
synced 2024-11-10 14:11:52 +00:00
io_uring: transform send/recvmsg() -ERESTARTSYS to -EINTR
We should never return -ERESTARTSYS to userspace, transform it into -EINTR. Cc: stable@vger.kernel.org # v5.3+ Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
0b8c0ec7ee
commit
441cdbd544
@ -1917,6 +1917,8 @@ static int io_send_recvmsg(struct io_kiocb *req, const struct io_uring_sqe *sqe,
|
||||
ret = fn(sock, msg, flags);
|
||||
if (force_nonblock && ret == -EAGAIN)
|
||||
return ret;
|
||||
if (ret == -ERESTARTSYS)
|
||||
ret = -EINTR;
|
||||
}
|
||||
|
||||
io_cqring_add_event(req, ret);
|
||||
|
Loading…
Reference in New Issue
Block a user