diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2009-10-08 00:09:58 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2009-10-08 00:09:58 (GMT) |
commit | ba83d7ea7338945c817bc28aa94a41947f2472a1 (patch) | |
tree | c3a36810523872ba84666dc94bb33315c7d456c8 | |
parent | daa0084325d4e748f334a223e1cd3800120e6055 (diff) |
Fixed an integer overflow in symbol name index.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@129 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
-rw-r--r-- | ChangeLog | 9 | ||||
-rw-r--r-- | src/format/elf/elf_def.h | 2 | ||||
-rw-r--r-- | src/format/elf/section.c | 2 | ||||
-rw-r--r-- | src/format/elf/section.h | 2 |
4 files changed, 12 insertions, 3 deletions
@@ -1,3 +1,12 @@ +09-10-08 Cyrille Bagard <nocbos@gmail.com> + + * src/format/elf/elf_def.h: + Typo. + + * src/format/elf/section.c: + * src/format/elf/section.h: + Fix an integer overflow in symbol name index. + 09-10-07 Cyrille Bagard <nocbos@gmail.com> * src/arch/artificial.c: diff --git a/src/format/elf/elf_def.h b/src/format/elf/elf_def.h index 2e5489b..d063dcf 100644 --- a/src/format/elf/elf_def.h +++ b/src/format/elf/elf_def.h @@ -203,7 +203,7 @@ typedef struct _elf64_shdr typedef union _elf_shdr { elf32_shdr shdr32; /* Version 32 bits */ - elf64_shdr shdr64; /* Version 32 bits */ + elf64_shdr shdr64; /* Version 64 bits */ } elf_shdr; diff --git a/src/format/elf/section.c b/src/format/elf/section.c index 940acdf..e019648 100644 --- a/src/format/elf/section.c +++ b/src/format/elf/section.c @@ -247,7 +247,7 @@ bool find_elf_section_content_by_name(const GElfFormat *format, const char *name * * ******************************************************************************/ -const char *extract_name_from_elf_string_section(const GElfFormat *format, const elf_shdr *section, uint16_t index) +const char *extract_name_from_elf_string_section(const GElfFormat *format, const elf_shdr *section, off_t index) { const char *result; /* Nom trouvé à renvoyer */ const bin_t *content; /* Contenu binaire à lire */ diff --git a/src/format/elf/section.h b/src/format/elf/section.h index 944fd7c..bc952a4 100644 --- a/src/format/elf/section.h +++ b/src/format/elf/section.h @@ -49,7 +49,7 @@ void get_elf_section_content(const GElfFormat *, const elf_shdr *, off_t *, off_ bool find_elf_section_content_by_name(const GElfFormat *, const char *, off_t *, off_t *, vmpa_t *); /* Identifie une chaîne de caractères dans une section adéquate. */ -const char *extract_name_from_elf_string_section(const GElfFormat *, const elf_shdr *, uint16_t); +const char *extract_name_from_elf_string_section(const GElfFormat *, const elf_shdr *, off_t); |