summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--plugins/androhelpers/try_n_catch.c4
2 files changed, 7 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 2cc26fb..4c9409e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+13-08-21 Cyrille Bagard <nocbos@gmail.com>
+
+ * plugins/androhelpers/try_n_catch.c:
+ Fix a bug: do not create links between routines.
+
13-08-17 Cyrille Bagard <nocbos@gmail.com>
* src/gtkext/graph/layout.c:
diff --git a/plugins/androhelpers/try_n_catch.c b/plugins/androhelpers/try_n_catch.c
index 2543641..79bf00e 100644
--- a/plugins/androhelpers/try_n_catch.c
+++ b/plugins/androhelpers/try_n_catch.c
@@ -132,13 +132,13 @@ static void attach_caught_code(const GLoadedBinary *binary, const GBinRoutine *r
/* Si des détachements sont nécessaires... */
- if (!g_arch_instruction_has_sources(first))
+ if (!g_arch_instruction_has_sources(first) && try->start_addr > 0)
{
prev = g_arch_instruction_get_prev_iter(instrs, first);
g_arch_instruction_link_with(prev, first, ILT_EXEC_FLOW);
}
- if (!g_arch_instruction_has_sources(next))
+ if (!g_arch_instruction_has_sources(next) && (try->start_addr > 0 || try->insn_count > 0))
{
prev = g_arch_instruction_get_prev_iter(instrs, next);
g_arch_instruction_link_with(prev, next, ILT_EXEC_FLOW);