summaryrefslogtreecommitdiff
path: root/src/analysis/decomp
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2013-02-03 00:47:09 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2013-02-03 00:47:09 (GMT)
commit48e663f21a6429787fec2c426f46024dad9cde08 (patch)
tree8ba7878c82de5f95aecef6148a88b3bda2cd84d7 /src/analysis/decomp
parent5b89c8369d2a26089f22be7c482e8254244ebc8c (diff)
Added more options to render braces (or not) around decompiled blocks.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@337 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'src/analysis/decomp')
-rw-r--r--src/analysis/decomp/decompiler.c3
-rw-r--r--src/analysis/decomp/il.c1
2 files changed, 4 insertions, 0 deletions
diff --git a/src/analysis/decomp/decompiler.c b/src/analysis/decomp/decompiler.c
index 67583bb..c36811d 100644
--- a/src/analysis/decomp/decompiler.c
+++ b/src/analysis/decomp/decompiler.c
@@ -186,6 +186,9 @@ static void prepare_all_routines_for_decomp(const GLoadedBinary *binary, const c
reduce_used_variables(dinstrs);
+
+ g_expr_block_set_border_behavior(G_EXPR_BLOCK(dinstrs), BBB_FORCE_ON);
+
g_binary_routine_set_decomp_instructions(routines[i], dinstrs);
diff --git a/src/analysis/decomp/il.c b/src/analysis/decomp/il.c
index 9e235a6..595cad1 100644
--- a/src/analysis/decomp/il.c
+++ b/src/analysis/decomp/il.c
@@ -736,6 +736,7 @@ static void build_switch_branches(GSwitchInstruction *decomp, GFlowBlock *block,
g_object_unref(G_OBJECT(sub_ctx));
close_case_decomp_instructions(case_dinstr, next_block, dests, i, dcount);
+ g_expr_block_set_border_behavior(G_EXPR_BLOCK(case_dinstr), BBB_FORCE_OFF);
if (info[i].imm != NULL)
{