about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAymeric Vincent <aymeric.vincent@cea.fr>2018-03-08 14:35:09 +0100
committerAymeric Vincent <aymeric.vincent@cea.fr>2018-03-09 09:25:49 +0100
commitefb3be7a3303f9d4cbf77a8ed676ccedf8d8373f (patch)
treed27fc1735e5ae440693805cf12b70bf03944e26c
parent33b13d0b47f8304c9b45e9a1e337b360592a8a87 (diff)
downloadmiasm-efb3be7a3303f9d4cbf77a8ed676ccedf8d8373f.tar.gz
miasm-efb3be7a3303f9d4cbf77a8ed676ccedf8d8373f.zip
Fix branches which currently have a useless CR field
-rw-r--r--miasm2/arch/ppc/arch.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/miasm2/arch/ppc/arch.py b/miasm2/arch/ppc/arch.py
index d47c2aad..313497a0 100644
--- a/miasm2/arch/ppc/arch.py
+++ b/miasm2/arch/ppc/arch.py
@@ -115,7 +115,7 @@ class instruction_ppc(instruction):
             name = name[:-2] + 'A'
 
         if name[-2:] != 'LR' and name[-3:] != 'CTR':
-            if self.is_conditional_jump(name):
+            if len(self.args) == 2:
                 address_index = 1
             else:
                 address_index = 0
@@ -144,7 +144,7 @@ class instruction_ppc(instruction):
             return [ LR ]
         elif 'CTR' in self.name:
             return [ CTR ]
-        elif self.is_conditional_jump(self.name):
+        elif len(self.args) == 2:
             address_index = 1
         else:
             address_index = 0