version 1.54, 2014/03/07 01:27:14 |
version 1.55, 2014/08/25 20:40:52 |
Line 232 _rtld_digest_dynamic(const char *execnam |
|
Line 232 _rtld_digest_dynamic(const char *execnam |
|
|
|
#ifdef HAVE_INITFINI_ARRAY |
#ifdef HAVE_INITFINI_ARRAY |
case DT_INIT_ARRAY: |
case DT_INIT_ARRAY: |
obj->init_array = |
obj->init_array = (Elf_Addr *)obj->relocbase + dynp->d_un.d_ptr; |
(fptr_t *)(obj->relocbase + dynp->d_un.d_ptr); |
|
dbg(("headers: DT_INIT_ARRAY at %p", |
dbg(("headers: DT_INIT_ARRAY at %p", |
obj->init_array)); |
obj->init_array)); |
break; |
break; |
Line 252 _rtld_digest_dynamic(const char *execnam |
|
Line 251 _rtld_digest_dynamic(const char *execnam |
|
#ifdef HAVE_INITFINI_ARRAY |
#ifdef HAVE_INITFINI_ARRAY |
case DT_FINI_ARRAY: |
case DT_FINI_ARRAY: |
obj->fini_array = |
obj->fini_array = |
(fptr_t *)(obj->relocbase + dynp->d_un.d_ptr); |
(Elf_Addr *)(obj->relocbase + dynp->d_un.d_ptr); |
dbg(("headers: DT_FINI_ARRAY at %p", |
dbg(("headers: DT_FINI_ARRAY at %p", |
obj->fini_array)); |
obj->fini_array)); |
break; |
break; |
Line 345 _rtld_digest_dynamic(const char *execnam |
|
Line 344 _rtld_digest_dynamic(const char *execnam |
|
obj->relalim = obj->pltrela; |
obj->relalim = obj->pltrela; |
} |
} |
|
|
#if defined(RTLD_LOADER) && defined(__HAVE_FUNCTION_DESCRIPTORS) |
|
if (init != 0) |
if (init != 0) |
obj->init = (void (*)(void)) |
obj->init = (Elf_Addr)obj->relocbase + init; |
_rtld_function_descriptor_alloc(obj, NULL, init); |
|
if (fini != 0) |
if (fini != 0) |
obj->fini = (void (*)(void)) |
obj->fini = (Elf_Addr)obj->relocbase + fini; |
_rtld_function_descriptor_alloc(obj, NULL, fini); |
|
#else |
|
if (init != 0) |
|
obj->init = (void (*)(void)) |
|
(obj->relocbase + init); |
|
if (fini != 0) |
|
obj->fini = (void (*)(void)) |
|
(obj->relocbase + fini); |
|
#endif |
|
|
|
if (dyn_rpath != NULL) { |
if (dyn_rpath != NULL) { |
_rtld_add_paths(execname, &obj->rpaths, obj->strtab + |
_rtld_add_paths(execname, &obj->rpaths, obj->strtab + |