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
e23233d7
Commit
e23233d7
authored
Mar 03, 2015
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ws2_32: Add a separate structure for async shutdowns.
Conflicts: dlls/ws2_32/socket.c
parent
9fa69b58
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
8 deletions
+14
-8
socket.c
dlls/ws2_32/socket.c
+14
-8
No files found.
dlls/ws2_32/socket.c
View file @
e23233d7
...
...
@@ -335,11 +335,18 @@ struct ws2_async_io
struct
ws2_async_io
*
next
;
};
struct
ws2_async_shutdown
{
struct
ws2_async_io
io
;
HANDLE
hSocket
;
IO_STATUS_BLOCK
iosb
;
int
type
;
};
struct
ws2_async
{
struct
ws2_async_io
io
;
HANDLE
hSocket
;
int
type
;
LPWSAOVERLAPPED
user_overlapped
;
LPWSAOVERLAPPED_COMPLETION_ROUTINE
completion_func
;
IO_STATUS_BLOCK
local_iosb
;
...
...
@@ -2266,7 +2273,7 @@ static NTSTATUS WS2_async_send(void* user, IO_STATUS_BLOCK* iosb, NTSTATUS statu
*/
static
NTSTATUS
WS2_async_shutdown
(
void
*
user
,
PIO_STATUS_BLOCK
iosb
,
NTSTATUS
status
,
void
**
apc
)
{
struct
ws2_async
*
wsa
=
user
;
struct
ws2_async
_shutdown
*
wsa
=
user
;
int
fd
,
err
=
1
;
switch
(
status
)
...
...
@@ -2297,25 +2304,24 @@ static NTSTATUS WS2_async_shutdown( void* user, PIO_STATUS_BLOCK iosb, NTSTATUS
*/
static
int
WS2_register_async_shutdown
(
SOCKET
s
,
int
type
)
{
struct
ws2_async
*
wsa
;
struct
ws2_async
_shutdown
*
wsa
;
NTSTATUS
status
;
TRACE
(
"s %04lx type %d
\n
"
,
s
,
type
);
wsa
=
HeapAlloc
(
GetProcessHeap
(),
0
,
FIELD_OFFSET
(
struct
ws2_async
,
iovec
[
1
]
)
);
wsa
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
*
wsa
)
);
if
(
!
wsa
)
return
WSAEFAULT
;
wsa
->
hSocket
=
SOCKET2HANDLE
(
s
);
wsa
->
type
=
type
;
wsa
->
completion_func
=
NULL
;
wsa
->
hSocket
=
SOCKET2HANDLE
(
s
);
wsa
->
type
=
type
;
SERVER_START_REQ
(
register_async
)
{
req
->
type
=
type
;
req
->
async
.
handle
=
wine_server_obj_handle
(
wsa
->
hSocket
);
req
->
async
.
callback
=
wine_server_client_ptr
(
WS2_async_shutdown
);
req
->
async
.
iosb
=
wine_server_client_ptr
(
&
wsa
->
local_
iosb
);
req
->
async
.
iosb
=
wine_server_client_ptr
(
&
wsa
->
iosb
);
req
->
async
.
arg
=
wine_server_client_ptr
(
wsa
);
req
->
async
.
cvalue
=
0
;
status
=
wine_server_call
(
req
);
...
...
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