summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2020-12-16 15:09:52 +0100
committerFlorian Weimer <fweimer@redhat.com>2020-12-16 15:13:40 +0100
commite7570f4131a6af9405af7b4fd1c31de807e7cf68 (patch)
tree0f11050a7a1b768fb0d683dc60412bc2a101c3a5 /elf/dl-sysdep.c
parent{nptl,htl}/semaphoreP.h: clean up (diff)
downloadglibc-e7570f4131a6af9405af7b4fd1c31de807e7cf68.tar.gz
glibc-e7570f4131a6af9405af7b4fd1c31de807e7cf68.tar.bz2
glibc-e7570f4131a6af9405af7b4fd1c31de807e7cf68.zip
Replace __libc_multiple_libcs with __libc_initial flag
Change sbrk to fail for !__libc_initial (in the generic implementation). As a result, sbrk is (relatively) safe to use for the __libc_initial case (from the main libc). It is therefore no longer necessary to avoid using it in that case (or updating the brk cache), and the __libc_initial flag does not need to be updated as part of dlmopen or static dlopen. As before, direct brk system calls on Linux may lead to memory corruption. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Diffstat (limited to 'elf/dl-sysdep.c')
-rw-r--r--elf/dl-sysdep.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/elf/dl-sysdep.c b/elf/dl-sysdep.c
index 854570821c..6cc4a76560 100644
--- a/elf/dl-sysdep.c
+++ b/elf/dl-sysdep.c
@@ -58,8 +58,6 @@ ElfW(Addr) _dl_base_addr;
#endif
int __libc_enable_secure attribute_relro = 0;
rtld_hidden_data_def (__libc_enable_secure)
-int __libc_multiple_libcs = 0; /* Defining this here avoids the inclusion
- of init-first. */
/* This variable contains the lowest stack address ever used. */
void *__libc_stack_end attribute_relro = NULL;
rtld_hidden_data_def(__libc_stack_end)