diff options
Diffstat (limited to 'elf/rtld.c')
-rw-r--r-- | elf/rtld.c | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -478,7 +478,7 @@ _dl_start_final (void *arg, struct dl_start_final_info *info) GL(dl_rtld_map).l_real = &GL(dl_rtld_map); GL(dl_rtld_map).l_map_start = (ElfW(Addr)) &__ehdr_start; GL(dl_rtld_map).l_map_end = (ElfW(Addr)) _end; - GL(dl_rtld_map).l_seal = 1; + GL(dl_rtld_map).l_seal = lt_seal_toseal; /* Copy the TLS related data if necessary. */ #ifndef DONT_USE_BOOTSTRAP_MAP # if NO_TLS_OFFSET != 0 @@ -1046,9 +1046,9 @@ ERROR: audit interface '%s' requires version %d (maximum supported version %d); /* Mark the DSO as being used for auditing. */ dlmargs.map->l_auditing = 1; - /* Seal the audit modules and their dependencies. */ - dlmargs.map->l_seal = lt_seal_toseal; - _dl_mseal_map (dlmargs.map, true); + /* Since audit modules can not be loaded with RTLD_NODELETE, force the + sealing of the modules and its dependencies. */ + _dl_mseal_map (dlmargs.map, true, true); } /* Load all audit modules. */ @@ -1131,7 +1131,7 @@ rtld_setup_main_map (struct link_map *main_map) /* And it was opened directly. */ ++main_map->l_direct_opencount; main_map->l_contiguous = 1; - main_map->l_seal = 1; + main_map->l_seal = lt_seal_toseal; /* A PT_LOAD segment at an unexpected address will clear the l_contiguous flag. The ELF specification says that PT_LOAD |