diff options
Diffstat (limited to 'elf')
-rw-r--r-- | elf/dl-close.c | 5 | ||||
-rw-r--r-- | elf/dl-fini.c | 2 | ||||
-rw-r--r-- | elf/dl-init.c | 3 |
3 files changed, 6 insertions, 4 deletions
diff --git a/elf/dl-close.c b/elf/dl-close.c index 3a6f294b19..6c17593a52 100644 --- a/elf/dl-close.c +++ b/elf/dl-close.c @@ -152,8 +152,9 @@ _dl_close (void *_map) /* Next try the old-style destructor. */ if (imap->l_info[DT_FINI] != NULL) - (*(void (*) (void)) ((void *) imap->l_addr - + imap->l_info[DT_FINI]->d_un.d_ptr)) (); + (*(void (*) (void)) DL_DT_FINI_ADDRESS + (imap, (void *) imap->l_addr + + imap->l_info[DT_FINI]->d_un.d_ptr)) (); } /* Store the new l_opencount value. */ diff --git a/elf/dl-fini.c b/elf/dl-fini.c index c7d4ebc86a..4ed3975bda 100644 --- a/elf/dl-fini.c +++ b/elf/dl-fini.c @@ -167,7 +167,7 @@ _dl_fini (void) /* Next try the old-style destructor. */ if (l->l_info[DT_FINI] != NULL) - ((fini_t) (l->l_addr + l->l_info[DT_FINI]->d_un.d_ptr)) (); + ((fini_t) DL_DT_FINI_ADDRESS (l, l->l_addr + l->l_info[DT_FINI]->d_un.d_ptr)) (); } } } diff --git a/elf/dl-init.c b/elf/dl-init.c index 683b94b9c7..627f823524 100644 --- a/elf/dl-init.c +++ b/elf/dl-init.c @@ -105,7 +105,8 @@ _dl_init (struct link_map *main_map, int argc, char **argv, char **env) */ if (l->l_info[DT_INIT] != NULL) { - init = (init_t) (l->l_addr + l->l_info[DT_INIT]->d_un.d_ptr); + init = (init_t) DL_DT_INIT_ADDRESS + (l, l->l_addr + l->l_info[DT_INIT]->d_un.d_ptr); /* Call the function. */ init (argc, argv, env); |