[Lldb-commits] [lldb] r175924 - <rdar://problem/13190981>
Greg Clayton
gclayton at apple.com
Fri Feb 22 14:23:56 PST 2013
Author: gclayton
Date: Fri Feb 22 16:23:55 2013
New Revision: 175924
URL: http://llvm.org/viewvc/llvm-project?rev=175924&view=rev
Log:
<rdar://problem/13190981>
Fixed an issue where if we got a 'A' async packet back from debugserver, we would resend the last continue command. We now correctly identify the packet as async (just like the 'O' stdout async packet) and we don't resend the continue command.
Modified:
lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
Modified: lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp?rev=175924&r1=175923&r2=175924&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp (original)
+++ lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp Fri Feb 22 16:23:55 2013
@@ -540,11 +540,11 @@ GDBRemoteCommunicationClient::SendContin
// may change if we are interrupted and we continue after an async packet...
std::string continue_packet(payload, packet_length);
- bool got_stdout = false;
+ bool got_async_packet = false;
while (state == eStateRunning)
{
- if (!got_stdout)
+ if (!got_async_packet)
{
if (log)
log->Printf ("GDBRemoteCommunicationClient::%s () sending continue packet: %s", __FUNCTION__, continue_packet.c_str());
@@ -554,7 +554,7 @@ GDBRemoteCommunicationClient::SendContin
m_private_is_running.SetValue (true, eBroadcastAlways);
}
- got_stdout = false;
+ got_async_packet = false;
if (log)
log->Printf ("GDBRemoteCommunicationClient::%s () WaitForPacket(%s)", __FUNCTION__, continue_packet.c_str());
@@ -737,7 +737,7 @@ GDBRemoteCommunicationClient::SendContin
case 'O':
// STDOUT
{
- got_stdout = true;
+ got_async_packet = true;
std::string inferior_stdout;
inferior_stdout.reserve(response.GetBytesLeft () / 2);
char ch;
@@ -750,6 +750,7 @@ GDBRemoteCommunicationClient::SendContin
case 'A':
// Async miscellaneous reply. Right now, only profile data is coming through this channel.
{
+ got_async_packet = true;
std::string input = response.GetStringRef().substr(1); // '1' to move beyond 'A'
if (m_partial_profile_data.length() > 0)
{
More information about the lldb-commits
mailing list