rtld: bump r_debug.r_version to 1 from current 0.
Add r_ldbase. Requested and reviewed by: emaste Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D27429
This commit is contained in:
parent
523a67bbee
commit
71df6a153f
@ -2272,8 +2272,10 @@ init_rtld(caddr_t mapbase, Elf_Auxinfo **aux_info)
|
||||
parse_rtld_phdr(&obj_rtld);
|
||||
obj_enforce_relro(&obj_rtld);
|
||||
|
||||
r_debug.r_version = R_DEBUG_VERSION;
|
||||
r_debug.r_brk = r_debug_state;
|
||||
r_debug.r_state = RT_CONSISTENT;
|
||||
r_debug.r_ldbase = obj_rtld.relocbase;
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -69,7 +69,7 @@ typedef struct link_map {
|
||||
} Link_map;
|
||||
|
||||
struct r_debug {
|
||||
int r_version; /* not used */
|
||||
int r_version; /* Currently '1' */
|
||||
struct link_map *r_map; /* list of loaded images */
|
||||
void (*r_brk)(struct r_debug *, struct link_map *);
|
||||
/* pointer to break point */
|
||||
@ -78,8 +78,11 @@ struct r_debug {
|
||||
RT_ADD, /* adding a shared library */
|
||||
RT_DELETE /* removing a shared library */
|
||||
} r_state;
|
||||
void *r_ldbase; /* Base address of rtld */
|
||||
};
|
||||
|
||||
#define R_DEBUG_VERSION 1
|
||||
|
||||
struct dl_phdr_info
|
||||
{
|
||||
Elf_Addr dlpi_addr; /* module relocation base */
|
||||
|
Loading…
Reference in New Issue
Block a user