Fix "debug next process" with hbldr homebrew

This commit is contained in:
TuxSH
2019-04-18 22:58:53 +02:00
parent 9e1a9f2842
commit eef22f8701
7 changed files with 86 additions and 5 deletions

View File

@@ -36,6 +36,7 @@
#include "gdb/watchpoints.h"
#include "gdb/breakpoints.h"
#include "gdb/stop_point.h"
#include "task_runner.h"
Result GDB_InitializeServer(GDBServer *server)
{
@@ -225,6 +226,10 @@ GDBContext *GDB_GetClient(GDBServer *server, u16 port)
GDB_UnlockAllContexts(server);
return NULL;
}
if (ctx->localPort == GDB_PORT_BASE + MAX_DEBUG)
TaskRunner_WaitReady(); // Finish grabbing new process debug, if anything...
ctx->flags |= GDB_FLAG_USED;
ctx->state = GDB_STATE_CONNECTED;
ctx->parent = server;