mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-12-22 02:12:06 +00:00
thermosphere: gdb: fix GDB_SendStopReply
This commit is contained in:
parent
66ba05b302
commit
6499d36722
1 changed files with 13 additions and 2 deletions
|
@ -110,12 +110,14 @@ int GDB_SendStopReply(GDBContext *ctx, const DebugEventInfo *info, bool asNotifi
|
|||
|
||||
switch(info->type) {
|
||||
case DBGEVENT_DEBUGGER_BREAK: {
|
||||
strcat(buf, "S02");
|
||||
n += GDB_ParseExceptionFrame(buf + n, info, 0);
|
||||
break;
|
||||
}
|
||||
|
||||
case DBGEVENT_CORE_ON: {
|
||||
if (ctx->catchThreadEvents) {
|
||||
strcat(buf, "T05create:;");
|
||||
n += GDB_ParseExceptionFrame(buf + n, info, SIGTRAP);
|
||||
strcat(buf, "create:;");
|
||||
} else {
|
||||
invalid = true;
|
||||
}
|
||||
|
@ -152,6 +154,7 @@ int GDB_SendStopReply(GDBContext *ctx, const DebugEventInfo *info, bool asNotifi
|
|||
case Exception_BreakpointLowerEl: {
|
||||
n += GDB_ParseExceptionFrame(buf + n, info, SIGTRAP);
|
||||
strcat(buf, "hwbreak:;");
|
||||
break;
|
||||
}
|
||||
|
||||
case Exception_WatchpointLowerEl: {
|
||||
|
@ -166,6 +169,12 @@ int GDB_SendStopReply(GDBContext *ctx, const DebugEventInfo *info, bool asNotifi
|
|||
n += GDB_ParseExceptionFrame(buf + n, info, SIGTRAP);
|
||||
sprintf(buf + n, "%swatch:%016lx;", kinds[cr.lsc], info->frame->far_el2);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case Exception_SoftwareStepLowerEl: {
|
||||
n += GDB_ParseExceptionFrame(buf + n, info, SIGTRAP);
|
||||
break;
|
||||
}
|
||||
|
||||
// Note: we don't really support 32-bit sw breakpoints, we'll still report them
|
||||
|
@ -174,6 +183,7 @@ int GDB_SendStopReply(GDBContext *ctx, const DebugEventInfo *info, bool asNotifi
|
|||
case Exception_SoftwareBreakpointA32: {
|
||||
n += GDB_ParseExceptionFrame(buf + n, info, SIGTRAP);
|
||||
strcat(buf, "swbreak:;");
|
||||
break;
|
||||
}
|
||||
|
||||
default: {
|
||||
|
@ -207,6 +217,7 @@ int GDB_SendStopReply(GDBContext *ctx, const DebugEventInfo *info, bool asNotifi
|
|||
return (int)total;
|
||||
} else {
|
||||
invalid = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue