summaryrefslogtreecommitdiff
path: root/src/format/elf
diff options
context:
space:
mode:
Diffstat (limited to 'src/format/elf')
-rw-r--r--src/format/elf/elf.c5
-rw-r--r--src/format/elf/symbols.c13
2 files changed, 15 insertions, 3 deletions
diff --git a/src/format/elf/elf.c b/src/format/elf/elf.c
index ea1f1ff..f485dbc 100644
--- a/src/format/elf/elf.c
+++ b/src/format/elf/elf.c
@@ -291,8 +291,13 @@ GBinFormat *g_elf_format_new(GBinContent *content, GExeFormat *parent)
}
+ /* TODO : à bouger dans un épilogue commun */
+
handle_binary_format(PGA_FORMAT_LOADER_LAST, G_BIN_FORMAT(result));
+ g_binary_format_delete_duplicated_symbols(G_BIN_FORMAT(result));
+
+ /* .... */
return G_BIN_FORMAT(result);
diff --git a/src/format/elf/symbols.c b/src/format/elf/symbols.c
index 57d14cd..c3c2ecd 100644
--- a/src/format/elf/symbols.c
+++ b/src/format/elf/symbols.c
@@ -135,10 +135,17 @@ bool load_elf_symbols(GElfFormat *format)
/* Symboles d'entrée, si encore besoin */
- result &= load_all_elf_basic_entry_points(format);
+ /**
+ * Le tri en préalable
+ */
+
+
g_binary_format_sort_symbols(G_BIN_FORMAT(format));
+
+ result &= load_all_elf_basic_entry_points(format);
+
return result;
}
@@ -563,8 +570,8 @@ static bool load_elf_internal_symbols(GElfFormat *format)
- //init_mrange(&range, &addr, ELF_SYM(format, sym, st_size));
- init_mrange(&range, &addr, 0);
+ init_mrange(&range, &addr, ELF_SYM(format, sym, st_size));
+ //init_mrange(&range, &addr, 0);
/* Première ébauche de nom */