Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
27b51ce6
Commit
27b51ce6
authored
Jan 24, 2011
by
Mike Kaplinskiy
Committed by
Alexandre Julliard
Jan 24, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ws2_32: Finish an overlapped send only if we sent everything.
parent
a06144d9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
6 deletions
+8
-6
socket.c
dlls/ws2_32/socket.c
+7
-3
sock.c
dlls/ws2_32/tests/sock.c
+1
-3
No files found.
dlls/ws2_32/socket.c
View file @
27b51ce6
...
...
@@ -1806,7 +1806,11 @@ static NTSTATUS WS2_async_send(void* user, IO_STATUS_BLOCK* iosb, NTSTATUS statu
if
(
result
>=
0
)
{
status
=
STATUS_SUCCESS
;
if
(
wsa
->
first_iovec
<
wsa
->
n_iovecs
)
status
=
STATUS_PENDING
;
else
status
=
STATUS_SUCCESS
;
iosb
->
Information
+=
result
;
}
else
if
(
errno
==
EINTR
||
errno
==
EAGAIN
)
...
...
@@ -3906,10 +3910,10 @@ static int WS2_sendto( SOCKET s, LPWSABUF lpBuffers, DWORD dwBufferCount,
wsa
->
completion_func
=
lpCompletionRoutine
;
release_sock_fd
(
s
,
fd
);
if
(
n
==
-
1
)
if
(
n
==
-
1
||
n
<
totalLength
)
{
iosb
->
u
.
Status
=
STATUS_PENDING
;
iosb
->
Information
=
0
;
iosb
->
Information
=
n
==
-
1
?
0
:
n
;
SERVER_START_REQ
(
register_async
)
{
...
...
dlls/ws2_32/tests/sock.c
View file @
27b51ce6
...
...
@@ -2848,10 +2848,8 @@ static void test_send(void)
bytes_sent
=
0
;
ret
=
WSASend
(
dst
,
&
buf
,
1
,
&
bytes_sent
,
0
,
&
ov
,
NULL
);
todo_wine
ok
((
ret
==
SOCKET_ERROR
&&
GetLastError
()
==
ERROR_IO_PENDING
)
||
broken
(
bytes_sent
==
buflen
),
ok
((
ret
==
SOCKET_ERROR
&&
GetLastError
()
==
ERROR_IO_PENDING
)
||
broken
(
bytes_sent
==
buflen
),
"Failed to start overlapped send %d - %d - %d/%d
\n
"
,
ret
,
WSAGetLastError
(),
bytes_sent
,
buflen
);
if
(
(
ret
!=
SOCKET_ERROR
||
GetLastError
()
!=
ERROR_IO_PENDING
)
&&
bytes_sent
<
buflen
)
goto
end
;
/* don't check for completion yet, we may need to drain the buffer while still sending */
set_blocking
(
src
,
FALSE
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment