Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F150310518
D52033.id160744.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
695 B
Referenced Files
None
Subscribers
None
D52033.id160744.diff
View Options
diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c
--- a/libexec/rtld-elf/rtld.c
+++ b/libexec/rtld-elf/rtld.c
@@ -2437,11 +2437,21 @@
{
const Elf_Phdr *ph;
Elf_Addr note_start, note_end;
+ bool first_seg;
+ first_seg = true;
obj->stack_flags = PF_X | PF_R | PF_W;
for (ph = obj->phdr;
(const char *)ph < (const char *)obj->phdr + obj->phsize; ph++) {
switch (ph->p_type) {
+ case PT_LOAD:
+ if (first_seg) {
+ obj->vaddrbase = rtld_trunc_page(ph->p_vaddr);
+ first_seg = false;
+ }
+ obj->mapsize = rtld_round_page(ph->p_vaddr +
+ ph->p_memsz) - obj->vaddrbase;
+ break;
case PT_GNU_STACK:
obj->stack_flags = ph->p_flags;
break;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Apr 1, 2:44 AM (10 h, 57 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30661345
Default Alt Text
D52033.id160744.diff (695 B)
Attached To
Mode
D52033: rtld: Compute obj->maxsize for obj_rtld
Attached
Detach File
Event Timeline
Log In to Comment