diff options
author | Adrian Prantl <aprantl@apple.com> | 2024-09-18 17:27:46 -0700 |
---|---|---|
committer | Adrian Prantl <aprantl@apple.com> | 2024-09-18 17:28:10 -0700 |
commit | 6dcde731eb13aeaa8296504ad8178d62c8ecd3eb (patch) | |
tree | 435b08e3b92f87b2326a14ecca09e66e4f05d574 /lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp | |
parent | cb6d53198e39838ba6f9d2974c4f4317057d1556 (diff) | |
download | llvm-6dcde731eb13aeaa8296504ad8178d62c8ecd3eb.zip llvm-6dcde731eb13aeaa8296504ad8178d62c8ecd3eb.tar.gz llvm-6dcde731eb13aeaa8296504ad8178d62c8ecd3eb.tar.bz2 |
Revert "[lldb] Only send "posix" error codes through the gdb-remote protocol"
This reverts commit a7c174502aef45b2d33291129cce10c085fef944.
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp')
-rw-r--r-- | lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp index d4aa90b..9b72cb0 100644 --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp @@ -103,14 +103,13 @@ GDBRemoteCommunicationServer::SendErrorResponse(uint8_t err) { GDBRemoteCommunication::PacketResult GDBRemoteCommunicationServer::SendErrorResponse(const Status &error) { - uint8_t code = error.GetType() == eErrorTypePOSIX ? error.GetError() : 0xff; if (m_send_error_strings) { lldb_private::StreamString packet; - packet.Printf("E%2.2x;", code); + packet.Printf("E%2.2x;", static_cast<uint8_t>(error.GetError())); packet.PutStringAsRawHex8(error.AsCString()); return SendPacketNoLock(packet.GetString()); - } - return SendErrorResponse(code); + } else + return SendErrorResponse(error.GetError()); } GDBRemoteCommunication::PacketResult |