summaryrefslogtreecommitdiff
path: root/src/arch/dalvik/decomp/aget.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch/dalvik/decomp/aget.c')
-rw-r--r--src/arch/dalvik/decomp/aget.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/arch/dalvik/decomp/aget.c b/src/arch/dalvik/decomp/aget.c
index 41b7e34..0fa66eb 100644
--- a/src/arch/dalvik/decomp/aget.c
+++ b/src/arch/dalvik/decomp/aget.c
@@ -2,7 +2,7 @@
/* OpenIDA - Outil d'analyse de fichiers binaires
* aget.c - décompilation des instructions manipulant des tableaux (chargement)
*
- * Copyright (C) 2010-2011 Cyrille Bagard
+ * Copyright (C) 2010-2012 Cyrille Bagard
*
* This file is part of OpenIDA.
*
@@ -46,19 +46,19 @@ GDecInstruction *dalvik_decomp_instr_aget(const GArchInstruction *instr, GDecCon
{
GDecInstruction *result; /* Instruction à retourner */
GArchOperand *operand; /* Opérande de l'instruction */
- GDecInstruction *content; /* Contenu de cellule visé */
GDecInstruction *array; /* Tableau accédé */
GDecInstruction *index; /* Indice de cellule considérée*/
+ GDecInstruction *content; /* Contenu de cellule visé */
GDecInstruction *access; /* Représentation de l'accès */
- operand = g_arch_instruction_get_operand(instr, 0);
- content = g_dec_context_convert_register(ctx, operand);
-
operand = g_arch_instruction_get_operand(instr, 1);
- array = g_dec_context_convert_register(ctx, operand);
+ array = g_dec_context_convert_register(ctx, operand, false);
operand = g_arch_instruction_get_operand(instr, 2);
- index = g_dec_context_convert_register(ctx, operand);
+ index = g_dec_context_convert_register(ctx, operand, false);
+
+ operand = g_arch_instruction_get_operand(instr, 0);
+ content = g_dec_context_convert_register(ctx, operand, true);
access = g_array_access_new(G_DEC_EXPRESSION(array), G_DEC_EXPRESSION(index));
result = g_assign_expression_new(G_DEC_EXPRESSION(content), G_DEC_EXPRESSION(access));