summaryrefslogtreecommitdiff
path: root/libc/malloc_hooks/malloc_hooks.cpp
diff options
context:
space:
mode:
authorTorne (Richard Coles) <torne@google.com>2019-04-02 17:04:42 -0400
committerTorne (Richard Coles) <torne@google.com>2019-04-02 18:06:12 -0400
commitfa9f7f28d4d3df6b1439553ed183efd421981616 (patch)
tree7bc371b05622827a39f375a7c43201c601e72b6d /libc/malloc_hooks/malloc_hooks.cpp
parente6fd53b751c253ce9315875bed838a6d549132f3 (diff)
Fix DLEXT_WRITE_RELRO when loading multiple libs.
ANDROID_DLEXT_WRITE_RELRO was causing the GNU RELRO sections of libraries to become corrupted if more than one library was being loaded at once (i.e. if the root library has DT_NEEDED entries for libraries that weren't already loaded). The file offset was not being correctly propagated between calls, so after writing out the (correct) RELRO data to the file, it was mapping the data at file offset 0 for all libraries, which corrupted the data for all but one of the libraries. Fix this by passing file_offset as a pointer the same way that phdr_table_map_gnu_relro does. Bug: 128623590 Test: tbd Change-Id: I196cd336bd5a67454e89fd85487356b1c7856871
Diffstat (limited to 'libc/malloc_hooks/malloc_hooks.cpp')
0 files changed, 0 insertions, 0 deletions