From f3e84729588f7e2e518f82116e908455d957f9ca Mon Sep 17 00:00:00 2001 From: Cyrille Bagard Date: Sun, 9 Oct 2016 14:01:00 +0200 Subject: Loaded Dex strings for annotations with the proper length. --- ChangeLog | 6 ++++++ plugins/readdex/ids.c | 12 ++++++++---- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 338dec9..a33e4ab 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 16-10-09 Cyrille Bagard + * plugins/readdex/ids.c: + Load Dex strings for annotations with the proper length, not the size + of the size. + +16-10-09 Cyrille Bagard + * src/format/dex/Makefile.am: Add the 'loading.[ch]' files to libformatdex_la_SOURCES. diff --git a/plugins/readdex/ids.c b/plugins/readdex/ids.c index 9319b7c..71e8569 100644 --- a/plugins/readdex/ids.c +++ b/plugins/readdex/ids.c @@ -123,12 +123,16 @@ bool annotate_dex_string_ids(const GDexFormat *format, GtkStatusStack *status) /* Description de la chaƮne : contenu */ - copy_vmpa(&start, &item_pos); - instr = g_raw_instruction_new_array(content, MDS_8_BITS, leb_size, &item_pos, endian); + if (length > 0) + { + copy_vmpa(&start, &item_pos); + instr = g_raw_instruction_new_array(content, MDS_8_BITS, length, &item_pos, endian); + + g_raw_instruction_mark_as_string(G_RAW_INSTRUCTION(instr), true); - g_raw_instruction_mark_as_string(G_RAW_INSTRUCTION(instr), true); + ADD_STR_AS_SYM(format, symbol, instr); - ADD_STR_AS_SYM(format, symbol, instr); + } gtk_status_stack_update_activity_value(status, msg, 1); -- cgit v0.11.2-87-g4458