summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2013-08-20 22:30:52 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2013-08-20 22:30:52 (GMT)
commit4658d4fa406bad4abe36a76746412cf02c984af0 (patch)
tree0cfd2b3c4b2ddccb33b69789c7845b61fb1871a9
parente53684bebd74d0a8ade79082c618ebb21bdea361 (diff)
Fixed a bug: do not create links between routines.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@357 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
-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);