mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-02 19:22:47 +00:00
Remove Obj_Entry textsize member.
It is unused after r340102, and more important, I do not see how to define textsize in both practically useful and correct way, for binaries with more that one executable segments. Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
32a8ec8bdd
commit
561991144e
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=340107
@ -287,7 +287,6 @@ map_object(int fd, const char *path, const struct stat *sb)
|
||||
}
|
||||
obj->mapbase = mapbase;
|
||||
obj->mapsize = mapsize;
|
||||
obj->textsize = text_end - base_vaddr;
|
||||
obj->vaddrbase = base_vaddr;
|
||||
obj->relocbase = mapbase - base_vaddr;
|
||||
obj->dynamic = (const Elf_Dyn *)(obj->relocbase + phdyn->p_vaddr);
|
||||
|
@ -1415,10 +1415,6 @@ digest_phdr(const Elf_Phdr *phdr, int phnum, caddr_t entry, const char *path)
|
||||
obj->vaddrbase;
|
||||
}
|
||||
nsegs++;
|
||||
if ((ph->p_flags & PF_X) == PF_X) {
|
||||
obj->textsize = MAX(obj->textsize,
|
||||
round_page(ph->p_vaddr + ph->p_memsz) - obj->vaddrbase);
|
||||
}
|
||||
break;
|
||||
|
||||
case PT_DYNAMIC:
|
||||
|
@ -151,7 +151,6 @@ typedef struct Struct_Obj_Entry {
|
||||
/* These items are computed by map_object() or by digest_phdr(). */
|
||||
caddr_t mapbase; /* Base address of mapped region */
|
||||
size_t mapsize; /* Size of mapped region in bytes */
|
||||
size_t textsize; /* Size of text segment in bytes */
|
||||
Elf_Addr vaddrbase; /* Base address in shared object file */
|
||||
caddr_t relocbase; /* Relocation constant = mapbase - vaddrbase */
|
||||
const Elf_Dyn *dynamic; /* Dynamic section */
|
||||
|
Loading…
Reference in New Issue
Block a user