summaryrefslogtreecommitdiffstats
path: root/lldb/test/functionalities
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/test/functionalities')
-rw-r--r--lldb/test/functionalities/process_attach/attach_denied/TestAttachDenied.py1
-rw-r--r--lldb/test/functionalities/process_attach/attach_denied/main.cpp8
2 files changed, 5 insertions, 4 deletions
diff --git a/lldb/test/functionalities/process_attach/attach_denied/TestAttachDenied.py b/lldb/test/functionalities/process_attach/attach_denied/TestAttachDenied.py
index 65d0c235cd6..33eb35ff313 100644
--- a/lldb/test/functionalities/process_attach/attach_denied/TestAttachDenied.py
+++ b/lldb/test/functionalities/process_attach/attach_denied/TestAttachDenied.py
@@ -21,7 +21,6 @@ class AttachDeniedTestCase(TestBase):
return (err, shell_command.GetStatus(), shell_command.GetOutput())
@skipIfWindows
- @skipIfLinux # hanging after reviews D13124 change went in
def test_attach_to_process_by_id_denied(self):
"""Test attach by process id denied"""
self.build()
diff --git a/lldb/test/functionalities/process_attach/attach_denied/main.cpp b/lldb/test/functionalities/process_attach/attach_denied/main.cpp
index b4a08d12b7e..ff1fccae4b1 100644
--- a/lldb/test/functionalities/process_attach/attach_denied/main.cpp
+++ b/lldb/test/functionalities/process_attach/attach_denied/main.cpp
@@ -54,7 +54,7 @@ bool writePid (const char* file_name, const pid_t pid)
return res;
}
-void sigterm_handler (int)
+void signal_handler (int)
{
}
@@ -75,8 +75,10 @@ int main (int argc, char const *argv[])
if (pid > 0)
{
- // Make pause call to return when SIGTERM is received.
- signal (SIGTERM, sigterm_handler);
+ // Make pause call to return when a signal is received. Normally this happens when the
+ // test runner tries to terminate us.
+ signal (SIGHUP, signal_handler);
+ signal (SIGTERM, signal_handler);
if (ptrace (ATTACH_REQUEST, pid, NULL, 0) == -1)
{
fprintf (stderr, "ptrace(ATTACH) failed: %s\n", strerror (errno));
OpenPOWER on IntegriCloud