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
d57c4199
Commit
d57c4199
authored
Nov 24, 2023
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Use RtlFindExportedRoutineByName to simplify loader initialization.
parent
74198569
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
9 deletions
+2
-9
loader.c
dlls/ntdll/loader.c
+2
-9
No files found.
dlls/ntdll/loader.c
View file @
d57c4199
...
...
@@ -4268,8 +4268,6 @@ void loader_init( CONTEXT *context, void **entry )
if
(
!
imports_fixup_done
)
{
MEMORY_BASIC_INFORMATION
meminfo
;
ANSI_STRING
base_thread_init_thunk
=
RTL_CONSTANT_STRING
(
"BaseThreadInitThunk"
);
ANSI_STRING
ctrl_routine
=
RTL_CONSTANT_STRING
(
"CtrlRoutine"
);
WINE_MODREF
*
kernel32
;
PEB
*
peb
=
NtCurrentTeb
()
->
Peb
;
...
...
@@ -4305,13 +4303,8 @@ void loader_init( CONTEXT *context, void **entry )
NtTerminateProcess
(
GetCurrentProcess
(),
status
);
}
node_kernel32
=
kernel32
->
ldr
.
DdagNode
;
if
((
status
=
LdrGetProcedureAddress
(
kernel32
->
ldr
.
DllBase
,
&
base_thread_init_thunk
,
0
,
(
void
**
)
&
pBaseThreadInitThunk
))
!=
STATUS_SUCCESS
)
{
MESSAGE
(
"wine: could not find BaseThreadInitThunk in kernel32.dll, status %lx
\n
"
,
status
);
NtTerminateProcess
(
GetCurrentProcess
(),
status
);
}
LdrGetProcedureAddress
(
kernel32
->
ldr
.
DllBase
,
&
ctrl_routine
,
0
,
(
void
**
)
&
pCtrlRoutine
);
pBaseThreadInitThunk
=
RtlFindExportedRoutineByName
(
kernel32
->
ldr
.
DllBase
,
"BaseThreadInitThunk"
);
pCtrlRoutine
=
RtlFindExportedRoutineByName
(
kernel32
->
ldr
.
DllBase
,
"CtrlRoutine"
);
actctx_init
();
locale_init
();
...
...
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