diff options
author | jdp <jdp@FreeBSD.org> | 1997-03-29 22:26:03 +0000 |
---|---|---|
committer | jdp <jdp@FreeBSD.org> | 1997-03-29 22:26:03 +0000 |
commit | 680df75eef352f77ca2d4671b7a7532b9c5bffc0 (patch) | |
tree | 85418bf01c727633cb7c84b1bd2f740b84a8eda7 /usr.bin | |
parent | bd506a8beff2cf320e8fa4ddc211c9cf201c25fe (diff) | |
download | FreeBSD-src-680df75eef352f77ca2d4671b7a7532b9c5bffc0.zip FreeBSD-src-680df75eef352f77ca2d4671b7a7532b9c5bffc0.tar.gz |
Fix broken built-in ELF file handling, caused by missing prototypes
and use of off_t. Correct the types of Elf64_Addr and Elf64_Off.
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/file/readelf.c | 4 | ||||
-rw-r--r-- | usr.bin/file/readelf.h | 6 |
2 files changed, 7 insertions, 3 deletions
diff --git a/usr.bin/file/readelf.c b/usr.bin/file/readelf.c index a007cca..2ae533b 100644 --- a/usr.bin/file/readelf.c +++ b/usr.bin/file/readelf.c @@ -11,6 +11,10 @@ #include "readelf.h" #include "file.h" +static void doshn __P((int, off_t, int, size_t, char *)); +static void dophn_exec __P((int, off_t, int, size_t, char *)); +static void dophn_core __P((int, off_t, int, size_t, char *)); + static void doshn(fd, off, num, size, buf) int fd; diff --git a/usr.bin/file/readelf.h b/usr.bin/file/readelf.h index c4b42d7..853eed6 100644 --- a/usr.bin/file/readelf.h +++ b/usr.bin/file/readelf.h @@ -1,6 +1,6 @@ /* * readelf.h - * @(#)$Id: readelf.h,v 1.4 1997/01/15 17:23:24 christos Exp $ + * @(#)$Id: readelf.h,v 1.1.1.1 1997/03/18 17:58:55 mpp Exp $ * * Provide elf data structures for non-elf machines, allowing file * non-elf hosts to determine if an elf binary is stripped. @@ -16,9 +16,9 @@ typedef unsigned int Elf32_Word; typedef unsigned char Elf32_Char; /* XXX: We need 64 bit numbers here */ -typedef unsigned int Elf64_Addr[2]; +typedef u_quad_t Elf64_Addr; typedef unsigned short Elf64_Half; -typedef unsigned int Elf64_Off[2]; +typedef u_quad_t Elf64_Off; typedef unsigned int Elf64_Word; typedef unsigned char Elf64_Char; |