Commit a06144d9 authored by Mike Kaplinskiy's avatar Mike Kaplinskiy Committed by Alexandre Julliard

ws2_32: Use the iosb to keep track of how many bytes we sent.

parent 388398bd
...@@ -1807,6 +1807,7 @@ static NTSTATUS WS2_async_send(void* user, IO_STATUS_BLOCK* iosb, NTSTATUS statu ...@@ -1807,6 +1807,7 @@ static NTSTATUS WS2_async_send(void* user, IO_STATUS_BLOCK* iosb, NTSTATUS statu
if (result >= 0) if (result >= 0)
{ {
status = STATUS_SUCCESS; status = STATUS_SUCCESS;
iosb->Information += result;
} }
else if (errno == EINTR || errno == EAGAIN) else if (errno == EINTR || errno == EAGAIN)
{ {
...@@ -1815,14 +1816,12 @@ static NTSTATUS WS2_async_send(void* user, IO_STATUS_BLOCK* iosb, NTSTATUS statu ...@@ -1815,14 +1816,12 @@ static NTSTATUS WS2_async_send(void* user, IO_STATUS_BLOCK* iosb, NTSTATUS statu
else else
{ {
status = wsaErrStatus(); status = wsaErrStatus();
result = 0;
} }
break; break;
} }
if (status != STATUS_PENDING) if (status != STATUS_PENDING)
{ {
iosb->u.Status = status; iosb->u.Status = status;
iosb->Information = result;
*apc = ws2_async_apc; *apc = ws2_async_apc;
} }
return status; return status;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment