diff options
| author | Camille Mougey <commial@gmail.com> | 2017-10-03 23:02:09 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-10-03 23:02:09 +0200 |
| commit | 58ed3f716b90da8d879aaa408f0c7ce1ea86a22c (patch) | |
| tree | 28af824c75ce2b67c3300f530e76971fdb98884a /example | |
| parent | b6b4b7360ecdabb9fc7949c461572754ce36a590 (diff) | |
| parent | 5f1e164fe1055a923856a0c82feaee92888c021f (diff) | |
| download | miasm-58ed3f716b90da8d879aaa408f0c7ce1ea86a22c.tar.gz miasm-58ed3f716b90da8d879aaa408f0c7ce1ea86a22c.zip | |
Merge pull request #618 from serpilliere/fix_propag
Ctypes: allow analysis on incomplete graphs
Diffstat (limited to 'example')
| -rw-r--r-- | example/ida/ctype_propagation.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/example/ida/ctype_propagation.py b/example/ida/ctype_propagation.py index c18abbfd..76d4fa2d 100644 --- a/example/ida/ctype_propagation.py +++ b/example/ida/ctype_propagation.py @@ -253,9 +253,10 @@ def analyse_function(): if (lbl, state) in done: continue done.add((lbl, state)) - symbexec_engine = TypePropagationEngine(ir_arch, types_mngr, state) + if lbl not in ir_arch.blocks: + continue - assert lbl in ir_arch.blocks + symbexec_engine = TypePropagationEngine(ir_arch, types_mngr, state) addr = symbexec_engine.emul_ir_block(lbl) symbexec_engine.del_mem_above_stack(ir_arch.sp) @@ -266,6 +267,8 @@ def analyse_function(): symbexec_engine.get_state()) for lbl, state in states.iteritems(): + if lbl not in ir_arch.blocks: + continue symbexec_engine = CTypeEngineFixer(ir_arch, types_mngr, state, cst_propag_link) addr = symbexec_engine.emul_ir_block(lbl) symbexec_engine.del_mem_above_stack(ir_arch.sp) |