Fix incorrect check of bool returning function.
I changed elf_map_image from returning an int to returning bool.
Unfortunately, I forgot to change this one check. The result is
the relative pc of any relocation packed shared libraries is
wrong.
Bug: 21271675
(cherry picked from commit 6732d3751a4ba4b23bd0881c5bd150e65c35c939)
Change-Id: I6fd4dc7e3e7b4a2f951a620c6fb95c93a2bcdfb5
diff --git a/src/os-linux.c b/src/os-linux.c
index 3c675a4..cebe5aa 100644
--- a/src/os-linux.c
+++ b/src/os-linux.c
@@ -73,7 +73,7 @@
if ((flags & (PROT_EXEC | PROT_READ)) == (PROT_EXEC | PROT_READ)
&& !(cur_map->flags & MAP_FLAGS_DEVICE_MEM))
{
- if (elf_map_image (&cur_map->ei, cur_map->path) == 0)
+ if (elf_map_image (&cur_map->ei, cur_map->path))
{
unw_word_t load_base;
if (elf_w (get_load_base) (&cur_map->ei, offset, &load_base))