Skip to content
Snippets Groups Projects
Commit a4c676ed authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

Fix apparent copy pasta of the total/len in recv.

parent ca62ed62
No related branches found
No related tags found
No related merge requests found
Pipeline #7645 passed
......@@ -339,7 +339,7 @@ static ptrdiff_t js_socket_recv(JSContext *cx, js_socket_private_t *p, void *buf
total += ret;
if ((!(flags & MSG_WAITALL)) || p->nonblocking)
return total;
if(total>=(ptrdiff_t)len)
if(ret>=(ptrdiff_t)len)
return total;
len-=ret;
buf=((uint8_t *)buf) + ret;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment