about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorserpilliere <devnull@localhost>2014-06-24 15:07:38 +0200
committerserpilliere <devnull@localhost>2014-06-24 15:07:38 +0200
commit664d19065919f0c9270d3960e4917de9000e9ca6 (patch)
treebf9fd4998ebad10e2b4be1b59a487c8d343fe4fd
parentf328270d56dd649bdeb87afac6d31c3c652b55ca (diff)
downloadmiasm-664d19065919f0c9270d3960e4917de9000e9ca6.tar.gz
miasm-664d19065919f0c9270d3960e4917de9000e9ca6.zip
Asmbloc: fix get_flow_instr for non zero delayslot arch
Diffstat (limited to '')
-rw-r--r--miasm2/core/asmbloc.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/miasm2/core/asmbloc.py b/miasm2/core/asmbloc.py
index 945eb990..98d6d2d7 100644
--- a/miasm2/core/asmbloc.py
+++ b/miasm2/core/asmbloc.py
@@ -217,6 +217,8 @@ class asm_bloc:
         if not self.lines:
             return None
         for i in xrange(-1, -1 - self.lines[0].delayslot - 1, -1):
+            if not 0 <= i < len(self.lines):
+                return None
             l = self.lines[i]
             if l.splitflow() or l.breakflow():
                 raise NotImplementedError('not fully functional')