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
26fbff05
Commit
26fbff05
authored
May 29, 2020
by
Paul Gofman
Committed by
Alexandre Julliard
May 29, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntoskrnl.exe: Implement image load notify routines registration.
Signed-off-by:
Paul Gofman
<
pgofman@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
a5b5be49
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
4 deletions
+25
-4
ntoskrnl.c
dlls/ntoskrnl.exe/ntoskrnl.c
+24
-4
ntddk.h
include/ddk/ntddk.h
+1
-0
No files found.
dlls/ntoskrnl.exe/ntoskrnl.c
View file @
26fbff05
...
...
@@ -85,6 +85,9 @@ static DWORD client_tid;
static
HANDLE
ntoskrnl_heap
;
static
PLOAD_IMAGE_NOTIFY_ROUTINE
load_image_notify_routines
[
8
];
static
unsigned
int
load_image_notify_routine_count
;
struct
wine_driver
{
DRIVER_OBJECT
driver_obj
;
...
...
@@ -3001,10 +3004,21 @@ NTSTATUS WINAPI PsRemoveCreateThreadNotifyRoutine( PCREATE_THREAD_NOTIFY_ROUTINE
/***********************************************************************
* PsRemoveLoadImageNotifyRoutine (NTOSKRNL.EXE.@)
*/
NTSTATUS
WINAPI
PsRemoveLoadImageNotifyRoutine
(
PLOAD_IMAGE_NOTIFY_ROUTINE
NotifyR
outine
)
NTSTATUS
WINAPI
PsRemoveLoadImageNotifyRoutine
(
PLOAD_IMAGE_NOTIFY_ROUTINE
r
outine
)
{
FIXME
(
"stub: %p
\n
"
,
NotifyRoutine
);
return
STATUS_SUCCESS
;
unsigned
int
i
;
TRACE
(
"routine %p.
\n
"
,
routine
);
for
(
i
=
0
;
i
<
load_image_notify_routine_count
;
++
i
)
if
(
load_image_notify_routines
[
i
]
==
routine
)
{
--
load_image_notify_routine_count
;
memmove
(
&
load_image_notify_routines
[
i
],
&
load_image_notify_routines
[
i
+
1
],
sizeof
(
*
load_image_notify_routines
)
*
(
load_image_notify_routine_count
-
i
));
return
STATUS_SUCCESS
;
}
return
STATUS_PROCEDURE_NOT_FOUND
;
}
...
...
@@ -3160,7 +3174,13 @@ NTSTATUS WINAPI IoWMIOpenBlock(LPCGUID guid, ULONG desired_access, PVOID *data_b
*/
NTSTATUS
WINAPI
PsSetLoadImageNotifyRoutine
(
PLOAD_IMAGE_NOTIFY_ROUTINE
routine
)
{
FIXME
(
"(%p) stub
\n
"
,
routine
);
FIXME
(
"routine %p, semi-stub.
\n
"
,
routine
);
if
(
load_image_notify_routine_count
==
ARRAY_SIZE
(
load_image_notify_routines
))
return
STATUS_INSUFFICIENT_RESOURCES
;
load_image_notify_routines
[
load_image_notify_routine_count
++
]
=
routine
;
return
STATUS_SUCCESS
;
}
...
...
include/ddk/ntddk.h
View file @
26fbff05
...
...
@@ -231,6 +231,7 @@ BOOLEAN WINAPI MmIsAddressValid(void *);
HANDLE
WINAPI
PsGetProcessId
(
PEPROCESS
);
HANDLE
WINAPI
PsGetThreadId
(
PETHREAD
);
HANDLE
WINAPI
PsGetThreadProcessId
(
PETHREAD
);
NTSTATUS
WINAPI
PsRemoveLoadImageNotifyRoutine
(
PLOAD_IMAGE_NOTIFY_ROUTINE
);
NTSTATUS
WINAPI
PsSetCreateProcessNotifyRoutine
(
PCREATE_PROCESS_NOTIFY_ROUTINE
,
BOOLEAN
);
NTSTATUS
WINAPI
PsSetCreateProcessNotifyRoutineEx
(
PCREATE_PROCESS_NOTIFY_ROUTINE_EX
,
BOOLEAN
);
NTSTATUS
WINAPI
PsSetCreateThreadNotifyRoutine
(
PCREATE_THREAD_NOTIFY_ROUTINE
);
...
...
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