From 7bcf0d3334e89bee5478c9a092a2c24d31fbb7ac Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Thu, 8 Nov 2018 22:43:51 +0800 Subject: [PATCH] sockets: Fix missing err_to_errno conversion for ERR_VAL in lwip_recvmsg Signed-off-by: Axel Lin --- src/api/sockets.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/sockets.c b/src/api/sockets.c index 44cab7ed..cb7df914 100644 --- a/src/api/sockets.c +++ b/src/api/sockets.c @@ -1305,7 +1305,7 @@ lwip_recvmsg(int s, struct msghdr *message, int flags) if ((message->msg_iov[i].iov_base == NULL) || ((ssize_t)message->msg_iov[i].iov_len <= 0) || ((size_t)(ssize_t)message->msg_iov[i].iov_len != message->msg_iov[i].iov_len) || ((ssize_t)(buflen + (ssize_t)message->msg_iov[i].iov_len) <= 0)) { - sock_set_errno(sock, ERR_VAL); + sock_set_errno(sock, err_to_errno(ERR_VAL)); done_socket(sock); return -1; }