Skip to content

Commit

Permalink
Make the launch operation async for dbgeng adapter
Browse files Browse the repository at this point in the history
  • Loading branch information
xusheng6 committed Apr 11, 2023
1 parent 9d4163f commit f1c1276
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions core/adapters/dbgengadapter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,6 @@ bool DbgEngAdapter::ExecuteWithArgsInternal(const std::string& path, const std::
{
if (this->m_debugControl->SetExecutionStatus(DEBUG_STATUS_GO) != S_OK)
return false;
Wait();
}

return true;
Expand All @@ -421,6 +420,7 @@ bool DbgEngAdapter::ExecuteWithArgsInternal(const std::string& path, const std::

void DbgEngAdapter::EngineLoop()
{
m_lastExecutionStatus = DEBUG_STATUS_NO_DEBUGGEE;
bool finished = false;
while (true)
{
Expand Down Expand Up @@ -487,7 +487,7 @@ void DbgEngAdapter::EngineLoop()
Wait();
}

m_lastExecutionStatus = DEBUG_STATUS_BREAK;
m_lastExecutionStatus = DEBUG_STATUS_NO_DEBUGGEE;
}

bool DbgEngAdapter::AttachInternal(std::uint32_t pid)
Expand Down
2 changes: 1 addition & 1 deletion core/adapters/dbgengadapter.h
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ namespace BinaryNinjaDebugger {
std::vector<DebugBreakpoint> m_debug_breakpoints {};
bool m_lastOperationIsStepInto = false;

uint64_t m_lastExecutionStatus = DEBUG_STATUS_BREAK;
uint64_t m_lastExecutionStatus = DEBUG_STATUS_NO_DEBUGGEE;

unsigned long m_exitCode {};

Expand Down

0 comments on commit f1c1276

Please sign in to comment.