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
bc524e92
Commit
bc524e92
authored
Jun 20, 2002
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Avoid loading programs into the DOS memory area.
parent
a4771071
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
pe_image.c
loader/pe_image.c
+4
-4
virtual.c
memory/virtual.c
+1
-0
No files found.
loader/pe_image.c
View file @
bc524e92
...
@@ -395,10 +395,11 @@ static int do_relocations( char *base, const IMAGE_NT_HEADERS *nt, const char *f
...
@@ -395,10 +395,11 @@ static int do_relocations( char *base, const IMAGE_NT_HEADERS *nt, const char *f
{
{
if
(
nt
->
OptionalHeader
.
ImageBase
==
0x400000
)
if
(
nt
->
OptionalHeader
.
ImageBase
==
0x400000
)
ERR
(
"Standard load address for a Win32 program (0x00400000) not available - security-patched kernel ?
\n
"
);
ERR
(
"Standard load address for a Win32 program (0x00400000) not available - security-patched kernel ?
\n
"
);
ERR
(
"FATAL: Need to relocate %s, but no relocation records present (%s). Try to run that file directly !
\n
"
,
else
filename
,
ERR
(
"FATAL: Need to relocate %s from addr %p, but %s
\n
"
,
filename
,
nt
->
OptionalHeader
.
ImageBase
,
(
nt
->
FileHeader
.
Characteristics
&
IMAGE_FILE_RELOCS_STRIPPED
)
?
(
nt
->
FileHeader
.
Characteristics
&
IMAGE_FILE_RELOCS_STRIPPED
)
?
"stripped during link"
:
"unknown reason
"
);
"relocation records are stripped"
:
"no relocation records present
"
);
return
0
;
return
0
;
}
}
...
@@ -822,4 +823,3 @@ void PE_InitTls( void )
...
@@ -822,4 +823,3 @@ void PE_InitTls( void )
TlsSetValue
(
wm
->
tlsindex
,
mem
);
TlsSetValue
(
wm
->
tlsindex
,
mem
);
}
}
}
}
memory/virtual.c
View file @
bc524e92
...
@@ -513,6 +513,7 @@ static LPVOID map_image( HANDLE hmapping, int fd, char *base, DWORD total_size,
...
@@ -513,6 +513,7 @@ static LPVOID map_image( HANDLE hmapping, int fd, char *base, DWORD total_size,
/* zero-map the whole range */
/* zero-map the whole range */
if
(
base
<
(
char
*
)
0x110000
)
base
=
0
;
/* make sure the DOS area remains free */
if
((
ptr
=
wine_anon_mmap
(
base
,
total_size
,
if
((
ptr
=
wine_anon_mmap
(
base
,
total_size
,
PROT_READ
|
PROT_WRITE
|
PROT_EXEC
,
0
))
==
(
char
*
)
-
1
)
PROT_READ
|
PROT_WRITE
|
PROT_EXEC
,
0
))
==
(
char
*
)
-
1
)
{
{
...
...
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