diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.h b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.h --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.h +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.h @@ -147,21 +147,6 @@ int SendLaunchEventDataPacket(const char *data, bool *was_supported = nullptr); - /// Sends a "vAttach:PID" where PID is in hex. - /// - /// \param[in] pid - /// A process ID for the remote gdb server to attach to. - /// - /// \param[out] response - /// The response received from the gdb server. If the return - /// value is zero, \a response will contain a stop reply - /// packet. - /// - /// \return - /// Zero if the attach was successful, or an error indicating - /// an error code. - int SendAttach(lldb::pid_t pid, StringExtractorGDBRemote &response); - /// Sends a GDB remote protocol 'I' packet that delivers stdin /// data to the remote process. /// diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp @@ -1369,24 +1369,6 @@ return m_qHostInfo_is_valid == eLazyBoolYes; } -int GDBRemoteCommunicationClient::SendAttach( - lldb::pid_t pid, StringExtractorGDBRemote &response) { - if (pid != LLDB_INVALID_PROCESS_ID) { - char packet[64]; - const int packet_len = - ::snprintf(packet, sizeof(packet), "vAttach;%" PRIx64, pid); - UNUSED_IF_ASSERT_DISABLED(packet_len); - assert(packet_len < (int)sizeof(packet)); - if (SendPacketAndWaitForResponse(packet, response) == - PacketResult::Success) { - if (response.IsErrorResponse()) - return response.GetError(); - return 0; - } - } - return -1; -} - int GDBRemoteCommunicationClient::SendStdinNotification(const char *data, size_t data_len) { StreamString packet;