diff options
author | Dmitriy Ivanov <dimitry@google.com> | 2015-04-28 15:49:26 -0700 |
---|---|---|
committer | Dmitriy Ivanov <dimitry@google.com> | 2015-04-29 16:46:41 -0700 |
commit | 0b9e1c6051a6c75bf9040fd1da6109988900d0ac (patch) | |
tree | 0ecc423a2b4df421d8d94f7b6f90d1804538babc /linker | |
parent | e97d519a6b5d5f3272a0c851dff7bcf1f8ac0157 (diff) | |
download | bionic-0b9e1c6051a6c75bf9040fd1da6109988900d0ac.zip bionic-0b9e1c6051a6c75bf9040fd1da6109988900d0ac.tar.gz bionic-0b9e1c6051a6c75bf9040fd1da6109988900d0ac.tar.bz2 |
linker: initialize system properties
Bug: http://b/20567629
Bug: https://code.google.com/p/chromium/issues/detail?id=478886
Change-Id: I8d2d89b749015e7fcd6e7ea646911f2e617dd1ba
(cherry picked from commit b4e5067cab9f17fa76bd7695f41a0b5070e10df8)
Diffstat (limited to 'linker')
-rw-r--r-- | linker/linker.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/linker/linker.cpp b/linker/linker.cpp index bc16686..0e657d6 100644 --- a/linker/linker.cpp +++ b/linker/linker.cpp @@ -3037,6 +3037,8 @@ static void init_linker_info_for_gdb(ElfW(Addr) linker_base) { insert_soinfo_into_debug_map(linker_soinfo_for_gdb); } +extern "C" int __system_properties_init(void); + /* * This code is called after the linker has linked itself and * fixed it's own GOT. It is safe to make references to externs @@ -3051,6 +3053,9 @@ static ElfW(Addr) __linker_init_post_relocation(KernelArgumentBlock& args, ElfW( // Initialize environment functions, and get to the ELF aux vectors table. linker_env_init(args); + // Initialize system properties + __system_properties_init(); // may use 'environ' + // If this is a setuid/setgid program, close the security hole described in // ftp://ftp.freebsd.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-02:23.stdio.asc if (get_AT_SECURE()) { |