diff options
author | Dale Rahn <drahn@cvs.openbsd.org> | 2002-09-14 22:54:35 +0000 |
---|---|---|
committer | Dale Rahn <drahn@cvs.openbsd.org> | 2002-09-14 22:54:35 +0000 |
commit | 7ee3a98094748205792472cb466a7c0e9f8f0845 (patch) | |
tree | a5ef6e7ab886a62c0255a5e8dd3ec9d6c651acc0 /distrib/common | |
parent | 68f158ef3e368562e30db0055347cccac0359fe3 (diff) |
Properly print out rd_root_size when running elfrdsetroot. ok art@
Diffstat (limited to 'distrib/common')
-rw-r--r-- | distrib/common/elfrdsetroot.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/distrib/common/elfrdsetroot.c b/distrib/common/elfrdsetroot.c index d3f8c97e685..2091e9fc83d 100644 --- a/distrib/common/elfrdsetroot.c +++ b/distrib/common/elfrdsetroot.c @@ -1,4 +1,4 @@ -/* $OpenBSD: elfrdsetroot.c,v 1.2 2001/09/18 15:27:36 jason Exp $ */ +/* $OpenBSD: elfrdsetroot.c,v 1.3 2002/09/14 22:54:34 drahn Exp $ */ /* $NetBSD: rdsetroot.c,v 1.2 1995/10/13 16:38:39 gwr Exp $ */ /* @@ -80,7 +80,7 @@ main(argc,argv) { int fd, n; int found; - int *ip; + u_int32_t *ip; Elf_Ehdr eh; Elf_Phdr *ph; int phsize; @@ -144,11 +144,12 @@ main(argc,argv) /* * Find value in the location: rd_root_size */ - ip = (int*) (dataseg + rd_root_size_off); + ip = (u_int32_t*) (dataseg + rd_root_size_off); rd_root_size_val = *ip; #ifdef DEBUG printf("rd_root_size val: 0x%08X (%d blocks)\n", - rd_root_size_val, (rd_root_size_val >> 9)); + (u_int32_t)rd_root_size_val, + (u_int32_t)(rd_root_size_val >> 9)); #endif /* |