summaryrefslogtreecommitdiff
path: root/src/arch/arm/v7
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch/arm/v7')
-rw-r--r--src/arch/arm/v7/fetch.c14
-rw-r--r--src/arch/arm/v7/link.c4
-rw-r--r--src/arch/arm/v7/post.c2
3 files changed, 19 insertions, 1 deletions
diff --git a/src/arch/arm/v7/fetch.c b/src/arch/arm/v7/fetch.c
index a1ddd3e..dee9aa2 100644
--- a/src/arch/arm/v7/fetch.c
+++ b/src/arch/arm/v7/fetch.c
@@ -94,6 +94,8 @@ void help_fetching_with_instruction_b_with_orig(GArchInstruction *instr, GArchPr
else assert(0);
+ g_object_unref(G_OBJECT(op));
+
target = pc + offset;
//g_armv7_context_define_encoding(context, target, iset);
@@ -157,6 +159,8 @@ void help_fetching_with_instruction_bl_with_orig(GArchInstruction *instr, GArchP
else assert(0);
+ g_object_unref(G_OBJECT(op));
+
target = pc + offset;
//g_armv7_context_define_encoding(context, target, iset);
@@ -210,6 +214,8 @@ void help_fetching_with_instruction_blx_with_dest(GArchInstruction *instr, GArch
else assert(0);
+ g_object_unref(G_OBJECT(op));
+
target = pc + offset;
//g_armv7_context_define_encoding(context, target, iset);
@@ -284,7 +290,7 @@ void help_fetching_with_instruction_bx_with_orig(GArchInstruction *instr, GArchP
hfwibwo_no_pc:
- ;
+ g_object_unref(G_OBJECT(op));
}
@@ -329,6 +335,8 @@ void help_fetching_with_instruction_cb_n_z(GArchInstruction *instr, GArchProcess
else assert(0);
+ g_object_unref(G_OBJECT(op));
+
target = pc + offset;
//g_armv7_context_define_encoding(context, target, AV7IS_THUMB);
@@ -405,6 +413,7 @@ void help_fetching_with_instruction_ldr_literal_with_orig(GArchInstruction *inst
if (!ret)
{
assert(0);
+ g_object_unref(G_OBJECT(op));
g_arch_instruction_unlock_operands(instr);
return;
}
@@ -416,6 +425,7 @@ void help_fetching_with_instruction_ldr_literal_with_orig(GArchInstruction *inst
if (!g_exe_format_translate_offset_into_vmpa(format, val_offset, &loaded_addr))
{
assert(0);
+ g_object_unref(G_OBJECT(op));
g_arch_instruction_unlock_operands(instr);
return;
}
@@ -433,6 +443,7 @@ void help_fetching_with_instruction_ldr_literal_with_orig(GArchInstruction *inst
if (!ret)
{
+ g_object_unref(G_OBJECT(op));
g_arch_instruction_unlock_operands(instr);
return;
}
@@ -484,6 +495,7 @@ void help_fetching_with_instruction_ldr_literal_with_orig(GArchInstruction *inst
new = g_imm_operand_new_from_value(MDS_32_BITS_UNSIGNED, target);
_g_arch_instruction_replace_operand(instr, op, new);
+ g_object_unref(G_OBJECT(op));
g_arch_instruction_unlock_operands(instr);
diff --git a/src/arch/arm/v7/link.c b/src/arch/arm/v7/link.c
index 63fb3ae..68cde7b 100644
--- a/src/arch/arm/v7/link.c
+++ b/src/arch/arm/v7/link.c
@@ -65,6 +65,8 @@ void handle_armv7_conditional_branch_from_register(GArchInstruction *instr, GArc
g_object_unref(G_OBJECT(reg));
+ g_object_unref(G_OBJECT(op));
+
}
@@ -107,4 +109,6 @@ void handle_armv7_return_from_pop(GArchInstruction *instr, GArchProcessor *proc,
}
+ g_object_unref(G_OBJECT(op));
+
}
diff --git a/src/arch/arm/v7/post.c b/src/arch/arm/v7/post.c
index 7d8ecb3..46a1792 100644
--- a/src/arch/arm/v7/post.c
+++ b/src/arch/arm/v7/post.c
@@ -92,6 +92,8 @@ void post_process_ldr_instructions(GArchInstruction *instr, GArchProcessor *proc
ppli_release:
+ g_object_unref(G_OBJECT(op));
+
g_arch_instruction_unlock_operands(instr);
}