summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/arch/arm/v7/post.c4
-rw-r--r--src/format/elf/helper_arm.c9
-rw-r--r--src/format/elf/symbols.c10
-rw-r--r--src/format/elf/symbols.h6
4 files changed, 9 insertions, 20 deletions
diff --git a/src/arch/arm/v7/post.c b/src/arch/arm/v7/post.c
index 17dcf62..dce9c86 100644
--- a/src/arch/arm/v7/post.c
+++ b/src/arch/arm/v7/post.c
@@ -280,8 +280,8 @@ void post_process_ldr_instructions(GArchInstruction *instr, GArchProcessor *proc
init_vmpa(&target, VMPA_NO_PHYSICAL, addr);
init_mrange(&trange, &target, 0);
- vmpa2_virt_to_string(&target, MDS_32_BITS, loc, NULL);
- snprintf(name, sizeof(name), "loccc_%s", loc + 2);
+ vmpa2_virt_to_string(&target, MDS_UNDEFINED, loc, NULL);
+ snprintf(name, sizeof(name), "loc_%s", loc + 2);
routine = g_binary_routine_new();
g_binary_routine_set_name(routine, strdup(name));
diff --git a/src/format/elf/helper_arm.c b/src/format/elf/helper_arm.c
index e44222f..efc8a3d 100644
--- a/src/format/elf/helper_arm.c
+++ b/src/format/elf/helper_arm.c
@@ -26,19 +26,10 @@
#include "elf-int.h"
#include "symbols.h"
-
-
-
-
-
#include "../mangling/demangler.h"
-/* symbols.c : Récupère la désignation d'un symbole donné. */
-//extern const char *get_elf_symbol_name(GElfFormat *, const elf_shdr *, const elf_shdr *, off_t);
-
-
diff --git a/src/format/elf/symbols.c b/src/format/elf/symbols.c
index 4c1811f..04ba3de 100644
--- a/src/format/elf/symbols.c
+++ b/src/format/elf/symbols.c
@@ -57,14 +57,6 @@ static bool load_all_elf_basic_entry_points(GElfFormat *);
-/* Récupère la définition complète d'un symbole donné. */
-bool get_elf_symbol_by_index(GElfFormat *, const elf_shdr *, off_t, elf_sym *);
-
-/* Récupère la désignation d'un symbole donné. */
-const char *get_elf_symbol_name(GElfFormat *, const elf_shdr *, const elf_shdr *, off_t);
-
-
-
@@ -187,7 +179,7 @@ static void register_elf_entry_point(GElfFormat *format, virt_t vaddr, phys_t le
init_vmpa(&addr, VMPA_NO_PHYSICAL, vaddr);
- if (g_binary_format_find_symbol_at(format, &addr, &symbol))
+ if (g_binary_format_find_symbol_at(G_BIN_FORMAT(format), &addr, &symbol))
{
g_object_unref(G_OBJECT(routine));
diff --git a/src/format/elf/symbols.h b/src/format/elf/symbols.h
index 634158d..086cb0d 100644
--- a/src/format/elf/symbols.h
+++ b/src/format/elf/symbols.h
@@ -37,6 +37,12 @@ bool get_elf_symbol_by_index(GElfFormat *, const elf_shdr *, off_t, elf_sym *);
/* Récupère la désignation d'un symbole donné. */
const char *get_elf_symbol_name(GElfFormat *, const elf_shdr *, const elf_shdr *, off_t);
+/* Récupère la définition complète d'un symbole donné. */
+bool get_elf_symbol_by_index(GElfFormat *, const elf_shdr *, off_t, elf_sym *);
+
+/* Récupère la désignation d'un symbole donné. */
+const char *get_elf_symbol_name(GElfFormat *, const elf_shdr *, const elf_shdr *, off_t);
+
#endif /* _FORMAT_ELF_SYMBOLS_H */