aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/linux/thread.c
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2009-04-29 18:54:44 -0700
committerRuss Cox <rsc@golang.org>2009-04-29 18:54:44 -0700
commit89f8238a996e08a0a7df85db81cf0338c89de244 (patch)
tree088ecddbc116a4f31d286205c094cfadca0496ad /src/runtime/linux/thread.c
parentd2e42f3e487d3450e3b236bb4584f3c8ec8b8d35 (diff)
downloadgo-89f8238a996e08a0a7df85db81cf0338c89de244.tar.xz
don't set CLONE_PTRACE -- it confuses strace
R=r DELTA=4 (3 added, 1 deleted, 0 changed) OCL=28063 CL=28065
Diffstat (limited to 'src/runtime/linux/thread.c')
-rw-r--r--src/runtime/linux/thread.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/runtime/linux/thread.c b/src/runtime/linux/thread.c
index 4375eca9fc..cc9ba161bf 100644
--- a/src/runtime/linux/thread.c
+++ b/src/runtime/linux/thread.c
@@ -237,12 +237,14 @@ newosproc(M *m, G *g, void *stk, void (*fn)(void))
int64 ret;
int32 flags;
+ /*
+ * note: strace gets confused if we use CLONE_PTRACE here.
+ */
flags = CLONE_PARENT /* getppid doesn't change in child */
| CLONE_VM /* share memory */
| CLONE_FS /* share cwd, etc */
| CLONE_FILES /* share fd table */
| CLONE_SIGHAND /* share sig handler table */
- | CLONE_PTRACE /* revisit - okay for now */
| CLONE_THREAD /* revisit - okay for now */
;