aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSzabolcs Nagy <szabolcs.nagy@arm.com>2022-04-20 09:54:31 +0100
committerSzabolcs Nagy <szabolcs.nagy@arm.com>2022-08-05 19:45:19 +0100
commit06fda784450ff505a14c0af87a5c68e153b08b31 (patch)
tree1d7f9ce04b4c1308e18fea989967e73ad8c2bd63
parenta0cbaef87cd3eda4667fdd3bc8df6b57dc7fc722 (diff)
downloadglibc-06fda784450ff505a14c0af87a5c68e153b08b31.tar
glibc-06fda784450ff505a14c0af87a5c68e153b08b31.tar.gz
glibc-06fda784450ff505a14c0af87a5c68e153b08b31.tar.bz2
glibc-06fda784450ff505a14c0af87a5c68e153b08b31.zip
cheri: rtld: fix _dl_start to return elfptr_t
Functions returning a pointer to the user entry need to use an int type that can represent pointers.
-rw-r--r--elf/rtld.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/elf/rtld.c b/elf/rtld.c
index cbbaf4a331..2c61935a21 100644
--- a/elf/rtld.c
+++ b/elf/rtld.c
@@ -416,15 +416,15 @@ DL_SYSINFO_IMPLEMENTATION
#endif
#ifdef DONT_USE_BOOTSTRAP_MAP
-static ElfW(Addr) _dl_start_final (void *arg);
+static elfptr_t _dl_start_final (void *arg);
#else
struct dl_start_final_info
{
struct link_map l;
RTLD_TIMING_VAR (start_time);
};
-static ElfW(Addr) _dl_start_final (void *arg,
- struct dl_start_final_info *info);
+static elfptr_t _dl_start_final (void *arg,
+ struct dl_start_final_info *info);
#endif
/* These are defined magically by the linker. */
@@ -446,10 +446,10 @@ RTLD_START
this function is not inlined (see below). */
#ifdef DONT_USE_BOOTSTRAP_MAP
-static inline ElfW(Addr) __attribute__ ((always_inline))
+static inline elfptr_t __attribute__ ((always_inline))
_dl_start_final (void *arg)
#else
-static ElfW(Addr) __attribute__ ((noinline))
+static elfptr_t __attribute__ ((noinline))
_dl_start_final (void *arg, struct dl_start_final_info *info)
#endif
{
@@ -515,7 +515,7 @@ _dl_start_final (void *arg, struct dl_start_final_info *info)
# define bootstrap_map info.l
#endif
-static ElfW(Addr) __attribute_used__
+static elfptr_t __attribute_used__
_dl_start (void *arg)
{
#ifdef DONT_USE_BOOTSTRAP_MAP