Prepare unittest support

This commit is contained in:
momo5502
2024-10-25 17:04:45 +02:00
parent 2c9718ce3f
commit a3a95ec829
14 changed files with 139 additions and 18 deletions

View File

@@ -425,7 +425,7 @@ namespace
bool switch_to_thread(const logger& logger, x64_emulator& emu, process_context& context, emulator_thread& thread)
{
if (thread.exit_status.has_value() || !thread.is_thread_ready(context))
if (!thread.is_thread_ready(context))
{
return false;
}
@@ -584,6 +584,11 @@ void emulator_thread::mark_as_ready(const NTSTATUS status)
bool emulator_thread::is_thread_ready(process_context& context)
{
if(this->exit_status.has_value())
{
return false;
}
if (this->waiting_for_alert)
{
if (this->alerted)