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
4e73595a
Commit
4e73595a
authored
Jun 10, 2002
by
Mike McCormack
Committed by
Alexandre Julliard
Jun 10, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Partially implement LdrGetDllHandle.
- Implement LdrGetProcedureAddress.
parent
b65c99b0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
44 additions
and
2 deletions
+44
-2
loader.c
dlls/ntdll/loader.c
+42
-0
ntdll.spec
dlls/ntdll/ntdll.spec
+2
-2
No files found.
dlls/ntdll/loader.c
View file @
4e73595a
...
...
@@ -19,6 +19,13 @@
#include "winbase.h"
#include "ntdef.h"
#include "winnt.h"
#include "ntddk.h"
#include "module.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
ntdll
);
NTSTATUS
WINAPI
LdrDisableThreadCalloutsForDll
(
HANDLE
hModule
)
{
...
...
@@ -27,3 +34,38 @@ NTSTATUS WINAPI LdrDisableThreadCalloutsForDll(HANDLE hModule)
else
return
STATUS_DLL_NOT_FOUND
;
}
/* FIXME : MODULE_FindModule should depend on LdrGetDllHandle, not vice-versa */
NTSTATUS
WINAPI
LdrGetDllHandle
(
ULONG
x
,
LONG
y
,
PUNICODE_STRING
name
,
PVOID
*
base
)
{
STRING
str
;
WINE_MODREF
*
wm
;
FIXME
(
"%08lx %08lx %s %p : partial stub
\n
"
,
x
,
y
,
debugstr_wn
(
name
->
Buffer
,
name
->
Length
),
base
);
*
base
=
0
;
RtlUnicodeStringToAnsiString
(
&
str
,
name
,
TRUE
);
wm
=
MODULE_FindModule
(
str
.
Buffer
);
if
(
!
wm
)
return
STATUS_DLL_NOT_FOUND
;
*
base
=
(
PVOID
)
wm
->
module
;
return
STATUS_SUCCESS
;
}
/* FIXME : MODULE_GetProcAddress should depend on LdrGetProcedureAddress, not vice-versa */
NTSTATUS
WINAPI
LdrGetProcedureAddress
(
PVOID
base
,
PANSI_STRING
name
,
ULONG
ord
,
PVOID
*
address
)
{
WARN
(
"%p %s %ld %p
\n
"
,
base
,
debugstr_an
(
name
->
Buffer
,
name
->
Length
),
ord
,
address
);
if
(
name
)
*
address
=
MODULE_GetProcAddress
(
(
HMODULE
)
base
,
name
->
Buffer
,
FALSE
);
else
*
address
=
MODULE_GetProcAddress
(
(
HMODULE
)
base
,
(
LPSTR
)
ord
,
FALSE
);
return
(
*
address
)
?
STATUS_SUCCESS
:
STATUS_DLL_NOT_FOUND
;
}
dlls/ntdll/ntdll.spec
View file @
4e73595a
...
...
@@ -41,8 +41,8 @@ name ntdll
@ stub LdrFindEntryForAddress
@ stub LdrFindResourceDirectory_U
@ stub LdrFindResource_U
@ st
ub
LdrGetDllHandle
@ st
ub
LdrGetProcedureAddress
@ st
dcall LdrGetDllHandle(long long ptr ptr)
LdrGetDllHandle
@ st
dcall LdrGetProcedureAddress(ptr ptr long ptr)
LdrGetProcedureAddress
@ stub LdrInitializeThunk
@ stub LdrLoadDll
@ stub LdrProcessRelocationBlock
...
...
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