diff options
author | Ulrich Drepper <drepper@redhat.com> | 2005-08-03 00:02:56 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2005-08-03 00:02:56 +0000 |
commit | 41de488a0ad6679e816dbab960351e5f62ab8ead (patch) | |
tree | d4387847c11e48ccc8fa55ace24bcd2a595d0d84 /libelf/elf_error.c | |
parent | c911c9efe553d9af2d4fb0d420d8b614983e16ac (diff) |
Add several more elflint tests:
- check whether dynamic section matches PT_DYNAMIC program header entry
- make sure text relocation flag is used correctly
libelf needed one extension for this.
Diffstat (limited to 'libelf/elf_error.c')
-rw-r--r-- | libelf/elf_error.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libelf/elf_error.c b/libelf/elf_error.c index 168ce113..b51962b9 100644 --- a/libelf/elf_error.c +++ b/libelf/elf_error.c @@ -243,6 +243,11 @@ static const char msgstr[] = (ELF_E_INVALID_PHDR_IDX \ + sizeof "program header only allowed in executables and shared objects") N_("file has no program header") + "\0" +#define ELF_E_INVALID_OFFSET_IDX \ + (ELF_E_NO_PHDR_IDX \ + + sizeof "file has no program header") + N_("invalid offset") }; @@ -289,7 +294,8 @@ static const uint_fast16_t msgidx[ELF_E_NUM] = [ELF_E_NOFILE] = ELF_E_NOFILE_IDX, [ELF_E_GROUP_NOT_REL] = ELF_E_GROUP_NOT_REL_IDX, [ELF_E_INVALID_PHDR] = ELF_E_INVALID_PHDR_IDX, - [ELF_E_NO_PHDR] = ELF_E_NO_PHDR_IDX + [ELF_E_NO_PHDR] = ELF_E_NO_PHDR_IDX, + [ELF_E_INVALID_OFFSET] = ELF_E_INVALID_OFFSET_IDX }; #define nmsgidx ((int) (sizeof (msgidx) / sizeof (msgidx[0]))) |