diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2017-03-06 18:48:16 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2017-03-06 18:48:16 (GMT) |
commit | 12b8a066d1d8dd8cbef587dc6fafed870604f49f (patch) | |
tree | 3eb6cfbab886b430a8479fda9a721f75ae806a4d /plugins/androhelpers | |
parent | 0320d85e480882c58f254640a54c6c6e190dbf47 (diff) |
Locked access to instruction operands when needed.
Diffstat (limited to 'plugins/androhelpers')
-rw-r--r-- | plugins/androhelpers/params.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/plugins/androhelpers/params.c b/plugins/androhelpers/params.c index 908d8c6..ea85b89 100644 --- a/plugins/androhelpers/params.c +++ b/plugins/androhelpers/params.c @@ -149,11 +149,13 @@ static void visit_all_method_operands(const GDexMethod *method, GArchInstruction iter != NULL; iter = g_arch_instruction_get_next_iter(instrs, iter, end)) { - count = g_arch_instruction_count_operands(iter); + g_arch_instruction_lock_operands(iter); + + count = _g_arch_instruction_count_operands(iter); for (i = 0; i < count; i++) { - operand = g_arch_instruction_get_operand(iter, i); + operand = _g_arch_instruction_get_operand(iter, i); if (G_IS_DALVIK_REGISTER_OPERAND(operand)) process_register_operand(method, operand); @@ -163,6 +165,8 @@ static void visit_all_method_operands(const GDexMethod *method, GArchInstruction } + g_arch_instruction_unlock_operands(iter); + } } |