summaryrefslogtreecommitdiffstats
path: root/lib/libc
diff options
context:
space:
mode:
authorguenther <guenther@openbsd.org>2016-03-06 05:29:30 +0000
committerguenther <guenther@openbsd.org>2016-03-06 05:29:30 +0000
commit00260ef5094acb06e4049b1e3a0e1350410d88f7 (patch)
treee7af98d5094f70828f83b34c5f90a5c6cb1f43be /lib/libc
parentLocalize some declarations to kern_exit.c: the last good reason to put (diff)
downloadwireguard-openbsd-00260ef5094acb06e4049b1e3a0e1350410d88f7.tar.xz
wireguard-openbsd-00260ef5094acb06e4049b1e3a0e1350410d88f7.zip
Document the PT_GET_THREAD_{FIRST,NEXT} requests
From Michal Mazurek (akfaew (at) jasminek.net)
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/sys/ptrace.226
1 files changed, 24 insertions, 2 deletions
diff --git a/lib/libc/sys/ptrace.2 b/lib/libc/sys/ptrace.2
index 0da7cc11703..c4424dd901e 100644
--- a/lib/libc/sys/ptrace.2
+++ b/lib/libc/sys/ptrace.2
@@ -1,8 +1,8 @@
-.\" $OpenBSD: ptrace.2,v 1.35 2015/12/01 07:50:03 deraadt Exp $
+.\" $OpenBSD: ptrace.2,v 1.36 2016/03/06 05:29:30 guenther Exp $
.\" $NetBSD: ptrace.2,v 1.3 1996/02/23 01:39:41 jtc Exp $
.\"
.\" This file is in the public domain.
-.Dd $Mdocdate: December 1 2015 $
+.Dd $Mdocdate: March 6 2016 $
.Dt PTRACE 2
.Os
.Sh NAME
@@ -301,6 +301,28 @@ The
.Fa data
argument should be set to
.Li sizeof(struct ptrace_state) .
+.It Dv PT_GET_THREAD_FIRST
+This request reads the thread ID of the traced process' first thread into the
+.Dq Li struct ptrace_thread_state
+pointed to by
+.Fa addr .
+The
+.Fa data
+argument should be set to
+.Li sizeof(struct ptrace_thread_state) .
+.It Dv PT_GET_THREAD_NEXT
+This request is just like
+.Dv PT_GET_THREAD_FIRST ,
+except it returns the thread ID of the subsequent thread.
+The
+.Dq Li struct ptrace_thread_state
+pointed to by
+.Fa addr
+must be initialized by a previous
+.Dv PT_GET_THREAD_FIRST
+or
+.Dv PT_GET_THREAD_NEXT
+request.
.El
.Pp
Additionally, machine-specific requests can exist.