diff options
author | Ulrich Drepper <drepper@redhat.com> | 2008-01-02 17:44:39 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2008-01-02 17:44:39 +0000 |
commit | 3cbdd387c752999255aea91600b5cfdefbeac7d0 (patch) | |
tree | 50c18bd26f8cd31f4c1aa3ce1d78bb98548659ba /src/elflint.c | |
parent | ad024afc93dcd0f4797b3e80bfb6b80c34da5c12 (diff) | |
download | elfutils-3cbdd387c752999255aea91600b5cfdefbeac7d0.tar.gz |
propagate from branch 'com.redhat.elfutils.disasm' (head d15b4eb794e81e477f9896fe82a74cb5ecf4514c)
to branch 'com.redhat.elfutils' (head eaacbf01f8cc89d043ec6eca9b5e35cb5c4cde06)
Diffstat (limited to 'src/elflint.c')
-rw-r--r-- | src/elflint.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/elflint.c b/src/elflint.c index 0121832e..85b24954 100644 --- a/src/elflint.c +++ b/src/elflint.c @@ -579,11 +579,10 @@ check_symtab (Ebl *ebl, GElf_Ehdr *ehdr, GElf_Shdr *shdr, int idx) idx, section_name (ebl, idx)); /* Search for an extended section index table section. */ - size_t cnt; Elf_Data *xndxdata = NULL; Elf32_Word xndxscnidx = 0; bool found_xndx = false; - for (cnt = 1; cnt < shnum; ++cnt) + for (size_t cnt = 1; cnt < shnum; ++cnt) if (cnt != (size_t) idx) { Elf_Scn *xndxscn = elf_getscn (ebl->elf, cnt); @@ -608,8 +607,8 @@ section [%2d] '%s': symbol table cannot have more than one extended index sectio if (shdr->sh_entsize != gelf_fsize (ebl->elf, ELF_T_SYM, 1, EV_CURRENT)) ERROR (gettext ("\ -section [%2zu] '%s': entry size is does not match ElfXX_Sym\n"), - cnt, section_name (ebl, cnt)); +section [%2u] '%s': entry size is does not match ElfXX_Sym\n"), + idx, section_name (ebl, idx)); /* Test the zeroth entry. */ GElf_Sym sym_mem; @@ -644,7 +643,7 @@ section [%2d] '%s': XINDEX for zeroth entry not zero\n"), xndxscnidx, section_name (ebl, xndxscnidx)); } - for (cnt = 1; cnt < shdr->sh_size / shdr->sh_entsize; ++cnt) + for (size_t cnt = 1; cnt < shdr->sh_size / shdr->sh_entsize; ++cnt) { sym = gelf_getsymshndx (data, xndxdata, cnt, &sym_mem, &xndx); if (sym == NULL) @@ -3958,3 +3957,6 @@ process_elf_file (Elf *elf, const char *prefix, const char *suffix, /* Free the resources. */ ebl_closebackend (ebl); } + + +#include "debugpred.h" |