Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F161818967
D4791.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
740 B
Referenced Files
None
Subscribers
None
D4791.diff
View Options
Index: head/libexec/rtld-elf/rtld.c
===================================================================
--- head/libexec/rtld-elf/rtld.c
+++ head/libexec/rtld-elf/rtld.c
@@ -1144,13 +1144,13 @@
* is mapped read-only. DT_MIPS_RLD_MAP is used instead.
*/
-#ifndef __mips__
case DT_DEBUG:
+ if (!obj->writable_dynamic)
+ break;
if (!early)
dbg("Filling in DT_DEBUG entry");
((Elf_Dyn*)dynp)->d_un.d_ptr = (Elf_Addr) &r_debug;
break;
-#endif
case DT_FLAGS:
if (dynp->d_un.d_val & DF_ORIGIN)
@@ -1331,6 +1331,8 @@
break;
case PT_DYNAMIC:
+ if (ph->p_flags & PROT_WRITE)
+ obj->writable_dynamic = true;
obj->dynamic = (const Elf_Dyn *)(ph->p_vaddr + obj->relocbase);
break;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jul 8, 3:03 AM (20 m, 59 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
34826979
Default Alt Text
D4791.diff (740 B)
Attached To
Mode
D4791: RFC populate DT_DEBUG on MIPS if PT_DYNAMIC is writable
Attached
Detach File
Event Timeline
Log In to Comment