about summary refs log tree commit diff stats
path: root/example/ida/depgraph.py
diff options
context:
space:
mode:
authorFabrice Desclaux <fabrice.desclaux@cea.fr>2018-02-09 10:16:58 +0100
committerFabrice Desclaux <fabrice.desclaux@cea.fr>2018-02-09 10:55:39 +0100
commitc63ae8e10af699f2cd7bacd14a39112f28cf71ab (patch)
tree32cb299fb122719f3679d38a5821d90a853cb179 /example/ida/depgraph.py
parent4b257d2d82c6323c6bc521017d0649b8cc7b3747 (diff)
downloadmiasm-c63ae8e10af699f2cd7bacd14a39112f28cf71ab.tar.gz
miasm-c63ae8e10af699f2cd7bacd14a39112f28cf71ab.zip
IRBlock: getitem/len on assignblks
Diffstat (limited to 'example/ida/depgraph.py')
-rw-r--r--example/ida/depgraph.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/example/ida/depgraph.py b/example/ida/depgraph.py
index a946706c..5342313a 100644
--- a/example/ida/depgraph.py
+++ b/example/ida/depgraph.py
@@ -110,13 +110,13 @@ Method to use:
         elif mode == 1:
             return value + 1
         else:
-            return len(self.ira.blocks[self.label].assignblks)
+            return len(self.ira.blocks[self.label])
 
     @property
     def elements(self):
         value = self.cbReg.value
         if value in self.stk_args:
-            line = self.ira.blocks[self.label].assignblks[self.line_nb].instr
+            line = self.ira.blocks[self.label][self.line_nb].instr
             arg_num = self.stk_args[value]
             stk_high = m2_expr.ExprInt(idc.GetSpd(line.offset), ir_arch.sp.size)
             stk_off = m2_expr.ExprInt(self.ira.sp.size/8 * arg_num, ir_arch.sp.size)
@@ -174,7 +174,7 @@ def treat_element():
 
     for node in graph.relevant_nodes:
         try:
-            offset = ir_arch.blocks[node.label].assignblks[node.line_nb].instr.offset
+            offset = ir_arch.blocks[node.label][node.line_nb].instr.offset
         except IndexError:
             print "Unable to highlight %s" % node
             continue