Commit 9227eb2c authored by Alexandre Julliard's avatar Alexandre Julliard

ntdll: Add a workaround for Ubuntu's stupid ptrace breakage.

parent dec7effa
...@@ -45,6 +45,9 @@ ...@@ -45,6 +45,9 @@
#ifdef HAVE_SYS_MMAN_H #ifdef HAVE_SYS_MMAN_H
#include <sys/mman.h> #include <sys/mman.h>
#endif #endif
#ifdef HAVE_SYS_PRCTL_H
# include <sys/prctl.h>
#endif
#ifdef HAVE_SYS_STAT_H #ifdef HAVE_SYS_STAT_H
# include <sys/stat.h> # include <sys/stat.h>
#endif #endif
...@@ -1013,6 +1016,10 @@ void server_init_process(void) ...@@ -1013,6 +1016,10 @@ void server_init_process(void)
#ifdef __APPLE__ #ifdef __APPLE__
send_server_task_port(); send_server_task_port();
#endif #endif
#if defined(__linux__) && defined(HAVE_PRCTL)
/* work around Ubuntu's ptrace breakage */
if (server_pid != -1) prctl( 0x59616d61 /* PR_SET_PTRACER */, server_pid );
#endif
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment