Pico w: socket: Correctly return negative error code from recv_into

This commit is contained in:
Jeff Epler 2022-10-12 11:34:25 -05:00
parent 62cbd3bcd8
commit ca9523b814
No known key found for this signature in database
GPG Key ID: D5BF15AB975AB4DE

View File

@ -1080,6 +1080,9 @@ int socketpool_socket_recv_into(socketpool_socket_obj_t *socket,
ret = lwip_raw_udp_receive(socket, (byte *)buf, len, NULL, NULL, &_errno);
break;
}
if (ret < 0) {
return -_errno;
}
return ret;
}