Handle bad conversion in wr GDB monitor command handler
This commit is contained in:
@@ -131,6 +131,16 @@ namespace DebugServer::Gdb::CommandPackets
|
|||||||
|
|
||||||
debugSession.connection.writePacket(ResponsePacket{StringService::toHex("Register written\n")});
|
debugSession.connection.writePacket(ResponsePacket{StringService::toHex("Register written\n")});
|
||||||
|
|
||||||
|
} catch (const std::invalid_argument& exception) {
|
||||||
|
debugSession.connection.writePacket(ResponsePacket{
|
||||||
|
StringService::toHex(
|
||||||
|
StringService::applyTerminalColor(
|
||||||
|
"Error: Invalid register value given\n",
|
||||||
|
StringService::TerminalColor::DARK_RED
|
||||||
|
)
|
||||||
|
)
|
||||||
|
});
|
||||||
|
|
||||||
} catch (const Exception& exception) {
|
} catch (const Exception& exception) {
|
||||||
debugSession.connection.writePacket(ResponsePacket{
|
debugSession.connection.writePacket(ResponsePacket{
|
||||||
StringService::toHex(
|
StringService::toHex(
|
||||||
|
|||||||
Reference in New Issue
Block a user