diff options
Diffstat (limited to 'elf/rtld.c')
-rw-r--r-- | elf/rtld.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/elf/rtld.c b/elf/rtld.c index de965da337..7ea06e44d7 100644 --- a/elf/rtld.c +++ b/elf/rtld.c @@ -42,6 +42,7 @@ #include <stap-probe.h> #include <stackinfo.h> #include <dl-keysetup.h> +#include <malloc/malloc-internal.h> #include <assert.h> @@ -716,6 +717,11 @@ security_init (void) #endif __pointer_chk_guard_local = keys.pointer; + /* Keep a copy of the computed keys, so that they can be obtained + during malloc initialization in libc.so. */ + GLRO (dl_malloc_header_guard) = keys.heap_header; + GLRO (dl_malloc_footer_guard) = keys.heap_footer; + /* We do not need the _dl_random value anymore. The less information we leave behind, the better, so clear the variable. */ |