Skip to content

Commit

Permalink
(__elf_preferred_address): Prefer gaps below main executable.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ulrich Drepper committed Jun 30, 2001
1 parent 33e25d2 commit e86f971
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sysdeps/powerpc/dl-machine.c
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ __elf_preferred_address(struct link_map *loader, size_t maplength,
mapend = l->l_map_end | (_dl_pagesize - 1);
assert (mapend > mapstart);

if (mapend >= high && high >= mapstart)
if ((mapend >= high || l == _dl_loaded) && high >= mapstart)
high = mapstart;
else if (mapend >= low && low >= mapstart)
low = mapend;
Expand Down

0 comments on commit e86f971

Please sign in to comment.