From b6c24c161900a035f5ea7193f4816b6d192d6ac8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Date: Sat, 1 Oct 2022 18:59:28 +0200 Subject: [lldb] [gdb-remote] Move ReadPacketWithOutputSupport() to client Move ReadPacketWithOutputSupport() from GDBRemoteCommunication to GDBRemoteClientBase. This function is client-specific and moving it there simplifies followup patches that split communication into separate thread. Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.llvm.org/D135028 --- .../Process/gdb-remote/GDBRemoteCommunication.cpp | 17 ----------------- 1 file changed, 17 deletions(-) (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp') diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp index b67cd7e..7daf003 100644 --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp @@ -221,23 +221,6 @@ GDBRemoteCommunication::PacketResult GDBRemoteCommunication::GetAck() { } GDBRemoteCommunication::PacketResult -GDBRemoteCommunication::ReadPacketWithOutputSupport( - StringExtractorGDBRemote &response, Timeout timeout, - bool sync_on_timeout, - llvm::function_ref output_callback) { - auto result = ReadPacket(response, timeout, sync_on_timeout); - while (result == PacketResult::Success && response.IsNormalResponse() && - response.PeekChar() == 'O') { - response.GetChar(); - std::string output; - if (response.GetHexByteString(output)) - output_callback(output); - result = ReadPacket(response, timeout, sync_on_timeout); - } - return result; -} - -GDBRemoteCommunication::PacketResult GDBRemoteCommunication::ReadPacket(StringExtractorGDBRemote &response, Timeout timeout, bool sync_on_timeout) { -- cgit v1.1