Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
e57d5003
Commit
e57d5003
authored
Jul 27, 2021
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wow64: Add thunks for the write watch syscalls.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
458b859d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
47 additions
and
0 deletions
+47
-0
syscall.h
dlls/wow64/syscall.h
+2
-0
virtual.c
dlls/wow64/virtual.c
+45
-0
No files found.
dlls/wow64/syscall.h
View file @
e57d5003
...
...
@@ -64,6 +64,7 @@
SYSCALL_ENTRY( NtFreeVirtualMemory ) \
SYSCALL_ENTRY( NtGetCurrentProcessorNumber ) \
SYSCALL_ENTRY( NtGetNlsSectionPtr ) \
SYSCALL_ENTRY( NtGetWriteWatch ) \
SYSCALL_ENTRY( NtListenPort ) \
SYSCALL_ENTRY( NtLoadKey ) \
SYSCALL_ENTRY( NtLoadKey2 ) \
...
...
@@ -113,6 +114,7 @@
SYSCALL_ENTRY( NtReplyWaitReceivePort ) \
SYSCALL_ENTRY( NtRequestWaitReplyPort ) \
SYSCALL_ENTRY( NtResetEvent ) \
SYSCALL_ENTRY( NtResetWriteWatch ) \
SYSCALL_ENTRY( NtRestoreKey ) \
SYSCALL_ENTRY( NtSaveKey ) \
SYSCALL_ENTRY( NtSecureConnectPort ) \
...
...
dlls/wow64/virtual.c
View file @
e57d5003
...
...
@@ -178,6 +178,38 @@ NTSTATUS WINAPI wow64_NtGetNlsSectionPtr( UINT *args )
/**********************************************************************
* wow64_NtGetWriteWatch
*/
NTSTATUS
WINAPI
wow64_NtGetWriteWatch
(
UINT
*
args
)
{
HANDLE
handle
=
get_handle
(
&
args
);
ULONG
flags
=
get_ulong
(
&
args
);
void
*
base
=
get_ptr
(
&
args
);
SIZE_T
size
=
get_ulong
(
&
args
);
ULONG
*
addr_ptr
=
get_ptr
(
&
args
);
ULONG
*
count_ptr
=
get_ptr
(
&
args
);
ULONG
*
granularity
=
get_ptr
(
&
args
);
ULONG_PTR
i
,
count
=
*
count_ptr
;
void
**
addresses
;
NTSTATUS
status
;
if
(
!
count
||
!
size
)
return
STATUS_INVALID_PARAMETER
;
if
(
flags
&
~
WRITE_WATCH_FLAG_RESET
)
return
STATUS_INVALID_PARAMETER
;
if
(
!
addr_ptr
)
return
STATUS_ACCESS_VIOLATION
;
addresses
=
RtlAllocateHeap
(
GetProcessHeap
(),
0
,
count
*
sizeof
(
*
addresses
)
);
if
(
!
(
status
=
NtGetWriteWatch
(
handle
,
flags
,
base
,
size
,
addresses
,
&
count
,
granularity
)))
{
for
(
i
=
0
;
i
<
count
;
i
++
)
addr_ptr
[
i
]
=
PtrToUlong
(
addresses
[
i
]
);
*
count_ptr
=
count
;
}
RtlFreeHeap
(
GetProcessHeap
(),
0
,
addresses
);
return
status
;
}
/**********************************************************************
* wow64_NtLockVirtualMemory
*/
NTSTATUS
WINAPI
wow64_NtLockVirtualMemory
(
UINT
*
args
)
...
...
@@ -280,6 +312,19 @@ NTSTATUS WINAPI wow64_NtReadVirtualMemory( UINT *args )
/**********************************************************************
* wow64_NtResetWriteWatch
*/
NTSTATUS
WINAPI
wow64_NtResetWriteWatch
(
UINT
*
args
)
{
HANDLE
process
=
get_handle
(
&
args
);
void
*
base
=
get_ptr
(
&
args
);
SIZE_T
size
=
get_ulong
(
&
args
);
return
NtResetWriteWatch
(
process
,
base
,
size
);
}
/**********************************************************************
* wow64_NtUnlockVirtualMemory
*/
NTSTATUS
WINAPI
wow64_NtUnlockVirtualMemory
(
UINT
*
args
)
...
...
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