summaryrefslogtreecommitdiff
path: root/ldso
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2004-02-10 11:47:57 +0000
committerEric Andersen <andersen@codepoet.org>2004-02-10 11:47:57 +0000
commitb340a56ee0c0f39329aa2397a81263215b25de7c (patch)
tree14e4187e38825b155ec546e33d148a8db2e44063 /ldso
parentc0847e68b7330e6897e3a07fd7f489ab2e8aeaba (diff)
Fix function prototype to match the official ELF standard hash function
Diffstat (limited to 'ldso')
-rw-r--r--ldso/include/dl-hash.h2
-rw-r--r--ldso/ldso/dl-hash.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/ldso/include/dl-hash.h b/ldso/include/dl-hash.h
index 246ed2608..2d41e009a 100644
--- a/ldso/include/dl-hash.h
+++ b/ldso/include/dl-hash.h
@@ -75,7 +75,7 @@ extern int _dl_linux_dynamic_link(void);
extern char * _dl_library_path;
extern char * _dl_not_lazy;
-extern unsigned long _dl_elf_hash(const char * name);
+extern unsigned long _dl_elf_hash(const unsigned char *name);
static inline int _dl_symbol(char * name)
{
diff --git a/ldso/ldso/dl-hash.c b/ldso/ldso/dl-hash.c
index c33b329ec..f69f0c171 100644
--- a/ldso/ldso/dl-hash.c
+++ b/ldso/ldso/dl-hash.c
@@ -57,7 +57,7 @@ struct dyn_elf *_dl_handles = NULL;
/* This is the hash function that is used by the ELF linker to generate the
* hash table that each executable and library is required to have. We need
* it to decode the hash table. */
-unsigned long _dl_elf_hash(const char *name)
+unsigned long _dl_elf_hash(const unsigned char *name)
{
unsigned long hash = 0;
unsigned long tmp;
@@ -67,7 +67,7 @@ unsigned long _dl_elf_hash(const char *name)
if ((tmp = hash & 0xf0000000))
hash ^= tmp >> 24;
hash &= ~tmp;
- };
+ }
return hash;
}