summaryrefslogtreecommitdiff
path: root/src/analysis/disass
diff options
context:
space:
mode:
Diffstat (limited to 'src/analysis/disass')
-rw-r--r--src/analysis/disass/fetch.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/analysis/disass/fetch.c b/src/analysis/disass/fetch.c
index c3ba2c2..b912ff2 100644
--- a/src/analysis/disass/fetch.c
+++ b/src/analysis/disass/fetch.c
@@ -67,7 +67,8 @@ static void follow_execution_flow(const GLoadedBinary *binary, GProcContext *ctx
printf("-- follow 0x%08x\n", (unsigned int)virt);
- g_proc_context_push_drop_point(ctx, virt);
+ if (virt == VMPA_NO_VIRTUAL)
+ g_proc_context_push_drop_point(ctx, virt);
while (g_proc_context_has_drop_points(ctx))
{
@@ -142,7 +143,7 @@ GArchInstruction *disassemble_binary_content(const GLoadedBinary *binary, GtkExt
{
GArchInstruction *result; /* Instruction désassemblées */
GBinFormat *format; /* Format du fichier binaire */
- GArchProcessor *proc; /* Architecture du binaire */
+ //GArchProcessor *proc; /* Architecture du binaire */
GProcContext *ctx; /* Contexte de désassemblage */
off_t length; /* Taille des données à lire */
mem_area *areas; /* Zone de productions */
@@ -157,9 +158,15 @@ GArchInstruction *disassemble_binary_content(const GLoadedBinary *binary, GtkExt
double done; /* Portion de travail accompli */
format = G_BIN_FORMAT(g_loaded_binary_get_format(binary));
+
+ /*
proc = get_arch_processor_from_format(G_EXE_FORMAT(format));
ctx = g_arch_processor_get_context(proc);
+ */
+
+ ctx = g_binary_format_get_disassembling_context(format);
+
/* Définition à la découpe des parties à traiter */
@@ -174,16 +181,9 @@ GArchInstruction *disassemble_binary_content(const GLoadedBinary *binary, GtkExt
_("Disassembling following the execution flow..."),
0, length);
- /* Insertion du point de départ */
-
- virt = g_binary_format_get_entry_point(format);
-
- follow_execution_flow(binary, ctx, &areas, &count, info, 0x84d0);
-
- follow_execution_flow(binary, ctx, &areas, &count, info, 0x84c5);
- follow_execution_flow(binary, ctx, &areas, &count, info, 0x8a65);
+ /* Insertion des points de départ */
- follow_execution_flow(binary, ctx, &areas, &count, info, virt);
+ follow_execution_flow(binary, ctx, &areas, &count, info, VMPA_NO_VIRTUAL);
/* Symboles exécutables présents et passés à travers les mailles */