diff options
author | peter <peter@FreeBSD.org> | 2002-04-11 09:30:15 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2002-04-11 09:30:15 +0000 |
commit | 961ff64e432f09c00e012312f7e00bcbd8c037ff (patch) | |
tree | 8d71150d38b125616cb499b29a3a7db228fcceac /usr.sbin/kldxref | |
parent | 48283ba193ac041d4210fc185e7494c5128ba634 (diff) | |
download | FreeBSD-src-961ff64e432f09c00e012312f7e00bcbd8c037ff.zip FreeBSD-src-961ff64e432f09c00e012312f7e00bcbd8c037ff.tar.gz |
Make kldxref work for Elf64 (which has 32 bit hash tables)
Diffstat (limited to 'usr.sbin/kldxref')
-rw-r--r-- | usr.sbin/kldxref/ef.c | 4 | ||||
-rw-r--r-- | usr.sbin/kldxref/ef.h | 10 |
2 files changed, 7 insertions, 7 deletions
diff --git a/usr.sbin/kldxref/ef.c b/usr.sbin/kldxref/ef.c index 74b1b09..4437eff 100644 --- a/usr.sbin/kldxref/ef.c +++ b/usr.sbin/kldxref/ef.c @@ -148,7 +148,7 @@ int ef_parse_dynamic(elf_file_t ef) { Elf_Dyn *dp; - Elf_Off hashhdr[2]; + Elf_Hashelt hashhdr[2]; /* int plttype = DT_REL;*/ int error; @@ -165,7 +165,7 @@ ef_parse_dynamic(elf_file_t ef) ef->ef_nbuckets = hashhdr[0]; ef->ef_nchains = hashhdr[1]; error = ef_read_entry(ef, -1, - (hashhdr[0] + hashhdr[1]) * sizeof(Elf_Off), + (hashhdr[0] + hashhdr[1]) * sizeof(Elf_Hashelt), (void**)&ef->ef_hashtab); if (error) { warnx("can't read hash table"); diff --git a/usr.sbin/kldxref/ef.h b/usr.sbin/kldxref/ef.h index 7dd110f..1609bb8 100644 --- a/usr.sbin/kldxref/ef.h +++ b/usr.sbin/kldxref/ef.h @@ -15,11 +15,11 @@ typedef struct elf_file { void* ef_fpage; /* First block of the file */ int ef_fplen; /* length of first block */ Elf_Dyn* ef_dyn; /* Symbol table etc. */ - Elf_Off ef_nbuckets; - Elf_Off ef_nchains; - Elf_Off* ef_buckets; - Elf_Off* ef_chains; - Elf_Off* ef_hashtab; + Elf_Hashelt ef_nbuckets; + Elf_Hashelt ef_nchains; + Elf_Hashelt* ef_buckets; + Elf_Hashelt* ef_chains; + Elf_Hashelt* ef_hashtab; Elf_Off ef_stroff; caddr_t ef_strtab; int ef_strsz; |