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
a0b57b9b
Commit
a0b57b9b
authored
Dec 10, 2021
by
Zebediah Figura
Committed by
Alexandre Julliard
Dec 10, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Handle WoW64 translation in IOCTL_AFD_RECV.
Signed-off-by:
Zebediah Figura
<
zfigura@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
e3e860e5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
43 additions
and
15 deletions
+43
-15
socket.c
dlls/ntdll/unix/socket.c
+35
-15
afd.h
include/wine/afd.h
+8
-0
No files found.
dlls/ntdll/unix/socket.c
View file @
a0b57b9b
...
@@ -1278,7 +1278,7 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc
...
@@ -1278,7 +1278,7 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc
case
IOCTL_AFD_RECV
:
case
IOCTL_AFD_RECV
:
{
{
const
struct
afd_recv_params
*
params
=
in_buffer
;
struct
afd_recv_params
params
;
int
unix_flags
=
0
;
int
unix_flags
=
0
;
if
((
status
=
server_get_unix_fd
(
handle
,
0
,
&
fd
,
&
needs_close
,
NULL
,
NULL
)))
if
((
status
=
server_get_unix_fd
(
handle
,
0
,
&
fd
,
&
needs_close
,
NULL
,
NULL
)))
...
@@ -1286,33 +1286,53 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc
...
@@ -1286,33 +1286,53 @@ NTSTATUS sock_ioctl( HANDLE handle, HANDLE event, PIO_APC_ROUTINE apc, void *apc
if
(
out_size
)
FIXME
(
"unexpected output size %u
\n
"
,
out_size
);
if
(
out_size
)
FIXME
(
"unexpected output size %u
\n
"
,
out_size
);
if
(
in_
size
<
sizeof
(
struct
afd_recv_params
))
if
(
in_
wow64_call
(
))
{
{
status
=
STATUS_INVALID_PARAMETER
;
const
struct
afd_recv_params_32
*
params32
=
in_buffer
;
break
;
if
(
in_size
<
sizeof
(
struct
afd_recv_params_32
))
{
status
=
STATUS_INVALID_PARAMETER
;
break
;
}
params
.
recv_flags
=
params32
->
recv_flags
;
params
.
msg_flags
=
params32
->
msg_flags
;
params
.
buffers
=
ULongToPtr
(
params32
->
buffers
);
params
.
count
=
params32
->
count
;
}
else
{
if
(
in_size
<
sizeof
(
struct
afd_recv_params
))
{
status
=
STATUS_INVALID_PARAMETER
;
break
;
}
memcpy
(
&
params
,
in_buffer
,
sizeof
(
params
)
);
}
}
if
((
params
->
msg_flags
&
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
))
==
0
||
if
((
params
.
msg_flags
&
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
))
==
0
||
(
params
->
msg_flags
&
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
))
==
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
))
(
params
.
msg_flags
&
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
))
==
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
))
{
{
status
=
STATUS_INVALID_PARAMETER
;
status
=
STATUS_INVALID_PARAMETER
;
break
;
break
;
}
}
if
(
params
->
msg_flags
&
~
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
|
AFD_MSG_PEEK
|
AFD_MSG_WAITALL
))
if
(
params
.
msg_flags
&
~
(
AFD_MSG_NOT_OOB
|
AFD_MSG_OOB
|
AFD_MSG_PEEK
|
AFD_MSG_WAITALL
))
FIXME
(
"unknown msg_flags %#x
\n
"
,
params
->
msg_flags
);
FIXME
(
"unknown msg_flags %#x
\n
"
,
params
.
msg_flags
);
if
(
params
->
recv_flags
&
~
AFD_RECV_FORCE_ASYNC
)
if
(
params
.
recv_flags
&
~
AFD_RECV_FORCE_ASYNC
)
FIXME
(
"unknown recv_flags %#x
\n
"
,
params
->
recv_flags
);
FIXME
(
"unknown recv_flags %#x
\n
"
,
params
.
recv_flags
);
if
(
params
->
msg_flags
&
AFD_MSG_OOB
)
if
(
params
.
msg_flags
&
AFD_MSG_OOB
)
unix_flags
|=
MSG_OOB
;
unix_flags
|=
MSG_OOB
;
if
(
params
->
msg_flags
&
AFD_MSG_PEEK
)
if
(
params
.
msg_flags
&
AFD_MSG_PEEK
)
unix_flags
|=
MSG_PEEK
;
unix_flags
|=
MSG_PEEK
;
if
(
params
->
msg_flags
&
AFD_MSG_WAITALL
)
if
(
params
.
msg_flags
&
AFD_MSG_WAITALL
)
FIXME
(
"MSG_WAITALL is not supported
\n
"
);
FIXME
(
"MSG_WAITALL is not supported
\n
"
);
status
=
sock_recv
(
handle
,
event
,
apc
,
apc_user
,
io
,
fd
,
params
->
buffers
,
params
->
count
,
NULL
,
status
=
sock_recv
(
handle
,
event
,
apc
,
apc_user
,
io
,
fd
,
params
.
buffers
,
params
.
count
,
NULL
,
NULL
,
NULL
,
NULL
,
unix_flags
,
!!
(
params
->
recv_flags
&
AFD_RECV_FORCE_ASYNC
)
);
NULL
,
NULL
,
NULL
,
unix_flags
,
!!
(
params
.
recv_flags
&
AFD_RECV_FORCE_ASYNC
)
);
break
;
break
;
}
}
...
...
include/wine/afd.h
View file @
a0b57b9b
...
@@ -107,6 +107,14 @@ struct afd_recv_params
...
@@ -107,6 +107,14 @@ struct afd_recv_params
int
msg_flags
;
int
msg_flags
;
};
};
struct
afd_recv_params_32
{
ULONG
buffers
;
unsigned
int
count
;
int
recv_flags
;
int
msg_flags
;
};
#include <pshpack4.h>
#include <pshpack4.h>
struct
afd_poll_params
struct
afd_poll_params
{
{
...
...
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