diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2016-12-29 10:30:28 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2016-12-29 10:30:28 (GMT) |
commit | 9f9041e11efa71cb043425cd5e89daea0247e76c (patch) | |
tree | 84d8704c291a5efef46af1e14a2aa3544dc29455 /src/gui | |
parent | 403a0519ec85a156a7f306b045d9cab619302473 (diff) |
Cut binary data into several areas using all the available CPUs and less memory.
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/panels/strings.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/panels/strings.c b/src/gui/panels/strings.c index b8631b6..38a17a2 100644 --- a/src/gui/panels/strings.c +++ b/src/gui/panels/strings.c @@ -465,7 +465,7 @@ static void change_strings_panel_current_binary(GStringsPanel *panel, GLoadedBin GArchProcessor *proc; /* Architecture du binaire */ MemoryDataSize msize; /* Taille par défaut */ GExeFormat *format; /* Format de travail */ - GPortionLayer *layer; /* Couche première de portions */ + GBinPortion *portions; /* Couche première de portions */ GBinContent *content; /* Contenu binaire en mémoire */ size_t count; /* Nombre des chaînes */ GBinSymbol **symbols; /* Liste des chaînes trouvées */ @@ -505,7 +505,7 @@ static void change_strings_panel_current_binary(GStringsPanel *panel, GLoadedBin g_object_unref(G_OBJECT(proc)); format = g_loaded_binary_get_format(binary); - layer = g_exe_format_get_main_layer(format); + portions = g_exe_format_get_portions(format); content = g_binary_format_get_content(G_BIN_FORMAT(format)); symbols = g_binary_format_get_symbols(G_BIN_FORMAT(format), &count); @@ -520,8 +520,9 @@ static void change_strings_panel_current_binary(GStringsPanel *panel, GLoadedBin vmpa2_phys_to_string(addr, msize, phys, NULL); vmpa2_virt_to_string(addr, msize, virt, NULL); - portion = g_portion_layer_find_portion_at_addr(layer, addr, (GdkRectangle []) { }); + portion = g_binary_portion_find_at_addr(portions, addr, (GdkRectangle []) { }); area = g_binary_portion_get_desc(portion); + g_object_unref(G_OBJECT(portion)); label = g_binary_symbol_get_label(symbols[i]); @@ -562,7 +563,7 @@ static void change_strings_panel_current_binary(GStringsPanel *panel, GLoadedBin } g_object_unref(G_OBJECT(content)); - g_object_unref(G_OBJECT(layer)); + g_object_unref(G_OBJECT(portions)); g_object_unref(G_OBJECT(format)); } |