From 620dd96217a49803fe04c6bc286291ddd857dcba Mon Sep 17 00:00:00 2001 From: Rusty Wagner Date: Sat, 3 Aug 2019 22:40:57 -0400 Subject: Expand support for HLIL switch/case and data flow access --- python/function.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'python/function.py') diff --git a/python/function.py b/python/function.py index dfb83e34..97f832d1 100644 --- a/python/function.py +++ b/python/function.py @@ -278,10 +278,16 @@ class ValueRange(object): class PossibleValueSet(object): - def __init__(self, arch, value): + def __init__(self, arch = None, value = None): + if value is None: + self._type = RegisterValueType.UndeterminedValue + return self._type = RegisterValueType(value.state) if value.state == RegisterValueType.EntryValue: - self._reg = arch.get_reg_name(value.value) + if arch is None: + self._reg = value.value + else: + self._reg = arch.get_reg_name(value.value) elif value.state == RegisterValueType.ConstantValue: self._value = value.value elif value.state == RegisterValueType.ConstantPointerValue: -- cgit v1.3.1