From d9c226b89d716205c3fa61f128cf468f1cac5e2c Mon Sep 17 00:00:00 2001 From: JP Smith Date: Thu, 20 Jul 2017 16:02:13 -0400 Subject: [PATCH] Fix forking state from memory (#407) * import ForkState before use * Fix ForkState behavior --- manticore/core/memory.py | 3 ++- manticore/core/state.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/manticore/core/memory.py b/manticore/core/memory.py index 9694d5a..c7b3327 100644 --- a/manticore/core/memory.py +++ b/manticore/core/memory.py @@ -954,7 +954,8 @@ class SMemory(Memory): condition = False for base in e.solutions: condition = Operators.OR(address == base, condition ) - raise ForkState(condition) + from .state import ForkState + raise ForkState("Forking state on incomplete result", condition) #So here we have all potential solutions to address assert len(solutions) > 0 diff --git a/manticore/core/state.py b/manticore/core/state.py index f4002cb..faed797 100644 --- a/manticore/core/state.py +++ b/manticore/core/state.py @@ -3,7 +3,7 @@ import copy import logging from collections import OrderedDict -from .smtlib import solver +from .smtlib import solver, Bool from ..utils.helpers import issymbolic from ..utils.event import Signal, forward_signals