summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--src/format/format-int.h3
-rw-r--r--src/format/format.c66
-rw-r--r--src/format/format.h4
4 files changed, 7 insertions, 73 deletions
diff --git a/ChangeLog b/ChangeLog
index f0cb810..d3ec17c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
17-05-14 Cyrille Bagard <nocbos@gmail.com>
+ * src/format/format-int.h:
+ * src/format/format.c:
+ * src/format/format.h:
+ Stop to memorize the routines as a subset of symbols.
+
+17-05-14 Cyrille Bagard <nocbos@gmail.com>
+
* src/analysis/disass/disassembler.c:
* src/analysis/disass/limit.c:
* src/analysis/disass/limit.h:
diff --git a/src/format/format-int.h b/src/format/format-int.h
index 30fb666..d50b053 100644
--- a/src/format/format-int.h
+++ b/src/format/format-int.h
@@ -69,9 +69,6 @@ struct _GBinFormat
size_t symbols_count; /* Quantité de ces symboles */
GRWLock syms_lock; /* Accès à la liste de symboles*/
- GBinRoutine **routines; /* Liste des routines trouvées */
- size_t routines_count; /* Nombre de ces routines */
-
const char **src_files; /* Nom des fichiers source */
size_t src_count; /* Taille de la liste */
size_t def_source; /* Fichier source principal */
diff --git a/src/format/format.c b/src/format/format.c
index d5cbda4..4dc6416 100644
--- a/src/format/format.c
+++ b/src/format/format.c
@@ -370,23 +370,6 @@ bool g_binary_format_add_symbol(GBinFormat *format, GBinSymbol *symbol)
result = true;
- switch (g_binary_symbol_get_target_type(symbol))
- {
- case STP_ROUTINE:
- case STP_ENTRY_POINT:
-
- routine = g_binary_symbol_get_routine(symbol);
-
- format->routines = qinsert(format->routines, &format->routines_count,
- sizeof(GBinRoutine *), (__compar_fn_t)g_binary_routine_compare,
- &routine);
- break;
-
- default:
- break;
-
- }
-
}
else
g_object_unref(G_OBJECT(symbol));
@@ -424,33 +407,6 @@ static void _g_binary_format_remove_symbol(GBinFormat *format, size_t index)
symbol = format->symbols[index];
- switch (g_binary_symbol_get_target_type(symbol))
- {
- case STP_ROUTINE:
- case STP_ENTRY_POINT:
-
- routine = g_binary_symbol_get_routine(symbol);
-
- for (i = 0; i < format->routines_count; i++)
- if (format->routines[i] == routine)
- break;
-
- assert(i < format->routines_count);
-
- if ((i + 1) < format->routines_count)
- memmove(&format->routines[i], &format->routines[i + 1],
- (format->routines_count - i - 1) * sizeof(GBinRoutine *));
-
- format->routines = (GBinRoutine **)realloc(format->routines,
- --format->routines_count * sizeof(GBinRoutine *));
-
- break;
-
- default:
- break;
-
- }
-
assert(index < format->symbols_count);
if ((index + 1) < format->symbols_count)
@@ -938,28 +894,6 @@ bool g_binary_format_resolve_symbol(GBinFormat *format, const vmpa2t *addr, bool
/******************************************************************************
* *
* Paramètres : format = informations chargées à consulter. *
-* count = taille du tableau créé. [OUT] *
-* *
-* Description : Fournit le prototype de toutes les routines détectées. *
-* *
-* Retour : Tableau créé ou NULL si aucun symbole de routine trouvé. *
-* *
-* Remarques : - *
-* *
-******************************************************************************/
-
-GBinRoutine **g_binary_format_get_routines(const GBinFormat *format, size_t *count)
-{
- *count = format->routines_count;
-
- return format->routines;
-
-}
-
-
-/******************************************************************************
-* *
-* Paramètres : format = informations chargées à consulter. *
* count = taille de la liste retournée. [OUT] *
* defsrc = fichier de code principal. [OUT] *
* *
diff --git a/src/format/format.h b/src/format/format.h
index e1c4e37..ec78236 100644
--- a/src/format/format.h
+++ b/src/format/format.h
@@ -32,7 +32,6 @@
#include "symbol.h"
#include "../analysis/content.h"
-#include "../analysis/routine.h"
#include "../arch/context.h"
#include "../gtkext/gtkstatusstack.h"
@@ -98,9 +97,6 @@ bool g_binary_format_find_next_symbol_at(GBinFormat *, const vmpa2t *, GBinSymbo
/* Recherche le symbole correspondant à une adresse. */
bool g_binary_format_resolve_symbol(GBinFormat *, const vmpa2t *, bool, GBinSymbol **, phys_t *);
-/* Fournit le prototype de toutes les routines détectées. */
-GBinRoutine **g_binary_format_get_routines(const GBinFormat *, size_t *);
-
/* Fournit la liste des fichiers source détectés. */
const char * const *g_binary_format_get_source_files(const GBinFormat *, size_t *, size_t *);