From 7b32ef0a6e084c15e98092e19c66190adc51a5d7 Mon Sep 17 00:00:00 2001 From: Nikhil Parasaram Date: Mon, 14 Jan 2019 20:19:18 +0530 Subject: [PATCH] Add the return constraints to global state --- mythril/laser/ethereum/svm.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mythril/laser/ethereum/svm.py b/mythril/laser/ethereum/svm.py index d84e1477..8d5c78e6 100644 --- a/mythril/laser/ethereum/svm.py +++ b/mythril/laser/ethereum/svm.py @@ -320,9 +320,8 @@ class LaserEVM: else: # First execute the post hook for the transaction ending instruction self._execute_post_hook(op_code, [end_signal.global_state]) - new_global_states = self._end_message_call( - return_global_state, + copy(return_global_state), global_state, revert_changes=False or end_signal.revert, return_data=transaction.return_data, @@ -347,6 +346,8 @@ class LaserEVM: :param return_data: :return: """ + + return_global_state.mstate.constraints += global_state.mstate.constraints # Resume execution of the transaction initializing instruction op_code = return_global_state.environment.code.instruction_list[ return_global_state.mstate.pc