From 14560a3610033925d703743b987c5f6bccddefc5 Mon Sep 17 00:00:00 2001 From: Luigi Rizzo Date: Tue, 6 Jan 2009 14:21:17 +0000 Subject: [PATCH] fix a couple of innocuous compiler warnings MFC after: 3 days --- usr.sbin/kldxref/ef_i386.c | 3 ++- usr.sbin/kldxref/ef_obj.c | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/usr.sbin/kldxref/ef_i386.c b/usr.sbin/kldxref/ef_i386.c index 49173543ae40..9b10c7d08ebf 100644 --- a/usr.sbin/kldxref/ef_i386.c +++ b/usr.sbin/kldxref/ef_i386.c @@ -43,12 +43,13 @@ */ int ef_reloc(struct elf_file *ef, const void *reldata, int reltype, Elf_Off relbase, - Elf_Off dataoff, size_t len, void *dest) + Elf_Off dataoff, size_t len, void *_dest) { Elf_Addr *where, addr, addend; Elf_Size rtype, symidx; const Elf_Rel *rel; const Elf_Rela *rela; + char *dest = _dest; switch (reltype) { case EF_RELOC_REL: diff --git a/usr.sbin/kldxref/ef_obj.c b/usr.sbin/kldxref/ef_obj.c index f58fa371f32e..5a4ae229541c 100644 --- a/usr.sbin/kldxref/ef_obj.c +++ b/usr.sbin/kldxref/ef_obj.c @@ -133,7 +133,7 @@ static struct elf_file_ops ef_obj_file_ops = { }; static int -ef_obj_get_type(elf_file_t ef) +ef_obj_get_type(elf_file_t __unused ef) { return (EFT_KLD); @@ -180,7 +180,7 @@ ef_obj_symaddr(elf_file_t ef, Elf_Size symidx) { const Elf_Sym *sym; - if (symidx >= ef->ddbsymcnt) + if (symidx >= (size_t) ef->ddbsymcnt) return (0); sym = ef->ddbsymtab + symidx;