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
0f0bf586
Commit
0f0bf586
authored
Feb 17, 2014
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Don't fixup imports for executables.
parent
7307298a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
10 deletions
+7
-10
loader.c
dlls/kernel32/tests/loader.c
+0
-1
loader.c
dlls/ntdll/loader.c
+7
-9
No files found.
dlls/kernel32/tests/loader.c
View file @
0f0bf586
...
@@ -1306,7 +1306,6 @@ static void test_import_resolution(void)
...
@@ -1306,7 +1306,6 @@ static void test_import_resolution(void)
ok
(
mod
!=
NULL
,
"failed to load err %u
\n
"
,
GetLastError
()
);
ok
(
mod
!=
NULL
,
"failed to load err %u
\n
"
,
GetLastError
()
);
if
(
!
mod
)
break
;
if
(
!
mod
)
break
;
ptr
=
(
struct
imports
*
)((
char
*
)
mod
+
page_size
);
ptr
=
(
struct
imports
*
)((
char
*
)
mod
+
page_size
);
todo_wine
ok
(
ptr
->
thunks
[
0
].
u1
.
Function
==
0xdeadbeef
,
"thunk resolved to %p for %s.%s
\n
"
,
ok
(
ptr
->
thunks
[
0
].
u1
.
Function
==
0xdeadbeef
,
"thunk resolved to %p for %s.%s
\n
"
,
(
void
*
)
ptr
->
thunks
[
0
].
u1
.
Function
,
data
.
module
,
data
.
function
.
name
);
(
void
*
)
ptr
->
thunks
[
0
].
u1
.
Function
,
data
.
module
,
data
.
function
.
name
);
FreeLibrary
(
mod
);
FreeLibrary
(
mod
);
...
...
dlls/ntdll/loader.c
View file @
0f0bf586
...
@@ -1509,12 +1509,8 @@ static void load_builtin_callback( void *module, const char *filename )
...
@@ -1509,12 +1509,8 @@ static void load_builtin_callback( void *module, const char *filename )
}
}
wm
->
ldr
.
Flags
|=
LDR_WINE_INTERNAL
;
wm
->
ldr
.
Flags
|=
LDR_WINE_INTERNAL
;
if
(
!
(
nt
->
FileHeader
.
Characteristics
&
IMAGE_FILE_DLL
)
&&
if
((
nt
->
FileHeader
.
Characteristics
&
IMAGE_FILE_DLL
)
||
!
NtCurrentTeb
()
->
Peb
->
ImageBaseAddress
)
/* if we already have an executable, ignore this one */
nt
->
OptionalHeader
.
Subsystem
==
IMAGE_SUBSYSTEM_NATIVE
)
{
NtCurrentTeb
()
->
Peb
->
ImageBaseAddress
=
module
;
}
else
{
{
/* fixup imports */
/* fixup imports */
...
@@ -1591,7 +1587,11 @@ static NTSTATUS load_native_dll( LPCWSTR load_path, LPCWSTR name, HANDLE file,
...
@@ -1591,7 +1587,11 @@ static NTSTATUS load_native_dll( LPCWSTR load_path, LPCWSTR name, HANDLE file,
/* fixup imports */
/* fixup imports */
if
(
!
(
flags
&
DONT_RESOLVE_DLL_REFERENCES
))
nt
=
RtlImageNtHeader
(
module
);
if
(
!
(
flags
&
DONT_RESOLVE_DLL_REFERENCES
)
&&
((
nt
->
FileHeader
.
Characteristics
&
IMAGE_FILE_DLL
)
||
nt
->
OptionalHeader
.
Subsystem
==
IMAGE_SUBSYSTEM_NATIVE
))
{
{
if
((
status
=
fixup_imports
(
wm
,
load_path
))
!=
STATUS_SUCCESS
)
if
((
status
=
fixup_imports
(
wm
,
load_path
))
!=
STATUS_SUCCESS
)
{
{
...
@@ -1612,8 +1612,6 @@ static NTSTATUS load_native_dll( LPCWSTR load_path, LPCWSTR name, HANDLE file,
...
@@ -1612,8 +1612,6 @@ static NTSTATUS load_native_dll( LPCWSTR load_path, LPCWSTR name, HANDLE file,
/* send DLL load event */
/* send DLL load event */
nt
=
RtlImageNtHeader
(
module
);
SERVER_START_REQ
(
load_dll
)
SERVER_START_REQ
(
load_dll
)
{
{
req
->
mapping
=
wine_server_obj_handle
(
mapping
);
req
->
mapping
=
wine_server_obj_handle
(
mapping
);
...
...
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