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
fa3544bb
Commit
fa3544bb
authored
Jun 03, 2004
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check for existing reserved areas in mmap_init to avoid doing
duplicate work.
parent
d6bd6b04
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
1 deletion
+16
-1
mmap.c
libs/wine/mmap.c
+16
-1
No files found.
libs/wine/mmap.c
View file @
fa3544bb
...
...
@@ -225,9 +225,24 @@ static void reserve_area( void *addr, void *end )
*/
void
mmap_init
(
void
)
{
static
char
*
const
user_space_limit
=
(
char
*
)
0x80000000
;
struct
reserved_area
*
area
;
struct
list
*
ptr
;
char
stack
;
char
*
const
stack_ptr
=
&
stack
;
char
*
user_space_limit
=
(
char
*
)
0x80000000
;
/* check for a reserved area starting at the user space limit */
/* to avoid wasting time trying to allocate it again */
LIST_FOR_EACH
(
ptr
,
&
reserved_areas
)
{
area
=
LIST_ENTRY
(
ptr
,
struct
reserved_area
,
entry
);
if
((
char
*
)
area
->
base
>
user_space_limit
)
break
;
if
((
char
*
)
area
->
base
+
area
->
size
>
user_space_limit
)
{
user_space_limit
=
(
char
*
)
area
->
base
+
area
->
size
;
break
;
}
}
if
(
stack_ptr
>=
user_space_limit
)
{
...
...
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