Replace DeepState_TakeOver() with Manticore function model

Now we have API parity with the angr executor, and return 1 from
`DeepState_TakeOver()` when it is hooked for symbolic execution under
the Manticore backend.
This commit is contained in:
Joe Ranweiler 2018-02-20 12:31:14 -08:00
parent 9e7266399c
commit 2ea978999b
No known key found for this signature in database
GPG Key ID: E0B6458CB03D167E

View File

@ -338,6 +338,10 @@ def do_run_test(state, apis, test):
m.add_hook(apis['ClearStream'], hook(hook_ClearStream))
m.add_hook(apis['LogStream'], hook(hook_LogStream))
# Here we hook `DeepState_TakeOver()`, even if running unit tests.
# In that case, we simply will never hit this hooked function model.
m.add_hook(test.ea, hook(hook_TakeOver))
m.subscribe('will_terminate_state', done_test)
m.run()