From 511e5cdce4020e221d3a8609492004e908ccfc1a Mon Sep 17 00:00:00 2001 From: Todd Fiala Date: Thu, 11 Sep 2014 23:29:14 +0000 Subject: llgs: fix Ctrl-C inferior interrupt handling to do the right thing. * Sends a SIGSTOP to the process. * Fixes busted SIGSTOP handling. Now builds a list of non-stopped that we wait for the PTRACE group-stop for. When the final must-stop tid gets its group stop, we propagate the process state change. Only the signal receiving the notification of the pending SIGSTOP is marked with the SIGSTOP signal. All the rest, if they weren't already stopped, are marked as stopped with signal 0. * Fixes a few broken tests. * Marks the Linux test I added earlier as expect-pass (no longer XFAIL). Implements fix for http://llvm.org/bugs/show_bug.cgi?id=20908. llvm-svn: 217647 --- .../Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp') diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp index bb3b32d3c10..e3aadf1bc25 100644 --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp @@ -3396,10 +3396,8 @@ GDBRemoteCommunicationServer::Handle_interrupt (StringExtractorGDBRemote &packet return SendErrorResponse (0x15); } - // Build the ResumeActionList - stop everything. - lldb_private::ResumeActionList actions (StateType::eStateStopped, 0); - - Error error = m_debugged_process_sp->Resume (actions); + // Interrupt the process. + Error error = m_debugged_process_sp->Interrupt (); if (error.Fail ()) { if (log) -- cgit v1.2.3