diff options
author | 2024-02-27 17:48:29 +0100 | |
---|---|---|
committer | 2024-02-27 11:48:29 -0500 | |
commit | 12129e0f93a96302f359b4a9ee6ba36c2b123fd1 (patch) | |
tree | 345a7e3f68beaef7a455796a88caaa7c1be96aff /src/osd | |
parent | 068704c298b23d717d6a13eed61fbb2f5a72ff65 (diff) |
gdbstub: fix checksum on Windows (#12067)
gdbstub: fix m68000 register names
Diffstat (limited to 'src/osd')
-rw-r--r-- | src/osd/modules/debugger/debuggdbstub.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/osd/modules/debugger/debuggdbstub.cpp b/src/osd/modules/debugger/debuggdbstub.cpp index 5ac83131abb..261ceb9beb5 100644 --- a/src/osd/modules/debugger/debuggdbstub.cpp +++ b/src/osd/modules/debugger/debuggdbstub.cpp @@ -253,9 +253,9 @@ static const gdb_register_map gdb_register_map_m68020pmmu = { "A4", "a4", false, TYPE_INT }, { "A5", "a5", false, TYPE_INT }, { "A6", "fp", true, TYPE_INT }, - { "A7", "sp", true, TYPE_INT }, + { "SP", "sp", true, TYPE_INT }, { "SR", "ps", false, TYPE_INT }, // NOTE GDB named it ps, but it's actually sr - { "PC", "pc", true, TYPE_CODE_POINTER }, + { "CURPC","pc", true, TYPE_CODE_POINTER }, } }; @@ -280,9 +280,9 @@ static const gdb_register_map gdb_register_map_m68000 = { "A4", "a4", false, TYPE_INT }, { "A5", "a5", false, TYPE_INT }, { "A6", "fp", true, TYPE_INT }, - { "A7", "sp", true, TYPE_INT }, + { "SP", "sp", true, TYPE_INT }, { "SR", "ps", false, TYPE_INT }, // NOTE GDB named it ps, but it's actually sr - { "PC", "pc", true, TYPE_CODE_POINTER }, + { "CURPC","pc", true, TYPE_CODE_POINTER }, //NOTE m68-elf-gdb complains about fpcontrol register not present but 68000 doesn't have floating point so... } }; @@ -682,6 +682,9 @@ static std::string escape_packet(const std::string src) result.reserve(src.length()); for ( char ch: src ) { + if ( ch == '\n' ) // don't let socket convert line endings and messing up the checksum + continue; + if ( ch == '#' || ch == '$' || ch == '}' ) { result += '}'; |