1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-25 14:33:52 +01:00

Merge pull request #16278 from iosabi/lwip_sock_tcp

lwip_sock: Fix computation of last_offset on partial reads.
This commit is contained in:
Martine Lenders 2021-04-07 13:06:45 +02:00 committed by GitHub
commit a433cb9fbe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -347,7 +347,7 @@ ssize_t sock_tcp_read(sock_tcp_t *sock, void *data, size_t max_len,
if (buf_len > copylen) {
/* there is still data in the buffer */
sock->last_buf = buf;
sock->last_offset = copylen;
sock->last_offset += copylen;
}
else {
sock->last_buf = NULL;