Skip to content

Commit

Permalink
Fix debug register logging
Browse files Browse the repository at this point in the history
  • Loading branch information
momo5502 committed Feb 4, 2025
1 parent 3d3bc39 commit 1fad315
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/windows-emulator/syscalls.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3550,7 +3550,7 @@ namespace
thread->restore(c.emu);

thread_context.access([&](CONTEXT64& context) {
if (context.ContextFlags & CONTEXT_DEBUG_REGISTERS_64)
if ((context.ContextFlags & CONTEXT_DEBUG_REGISTERS_64) == CONTEXT_DEBUG_REGISTERS_64)
{
c.win_emu.log.print(color::pink, "--> Reading debug registers!\n");
}
Expand Down Expand Up @@ -3588,6 +3588,12 @@ namespace

const auto context = thread_context.read();
context_frame::restore(c.emu, context);

if ((context.ContextFlags & CONTEXT_DEBUG_REGISTERS_64) == CONTEXT_DEBUG_REGISTERS_64)
{
c.win_emu.log.print(color::pink, "--> Setting debug registers!\n");
}

return STATUS_SUCCESS;
}

Expand Down

0 comments on commit 1fad315

Please sign in to comment.