aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/sys/linux/dl/dl-load.c
diff options
context:
space:
mode:
Diffstat (limited to 'newlib/libc/sys/linux/dl/dl-load.c')
-rw-r--r--newlib/libc/sys/linux/dl/dl-load.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/newlib/libc/sys/linux/dl/dl-load.c b/newlib/libc/sys/linux/dl/dl-load.c
index 65b72c7..4e32d60 100644
--- a/newlib/libc/sys/linux/dl/dl-load.c
+++ b/newlib/libc/sys/linux/dl/dl-load.c
@@ -1095,7 +1095,7 @@ _dl_map_object_from_fd (const char *name, int fd, struct filebuf *fbp,
}
else
/* Adjust the PT_PHDR value by the runtime load address. */
- (ElfW(Addr)) l->l_phdr += l->l_addr;
+ l->l_phdr = (ElfW(Addr)) l->l_phdr + l->l_addr;
}
/* We are done mapping in the file. We no longer need the descriptor. */
@@ -1115,7 +1115,7 @@ _dl_map_object_from_fd (const char *name, int fd, struct filebuf *fbp,
}
}
else
- (ElfW(Addr)) l->l_ld += l->l_addr;
+ l->l_ld = (ElfW(Addr)) l->l_ld + l->l_addr;
l->l_entry += l->l_addr;