diff options
Diffstat (limited to 'man2/getpid.2')
-rw-r--r-- | man2/getpid.2 | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/man2/getpid.2 b/man2/getpid.2 index 811270f05..5be89ddd5 100644 --- a/man2/getpid.2 +++ b/man2/getpid.2 @@ -27,9 +27,9 @@ This will be either the ID of the process that created this process using .BR fork (), or, if that process has already terminated, the ID of the process to which this process has been reparented (either -.BR init (1) +.MR init 1 or a "subreaper" process defined via the -.BR prctl (2) +.MR prctl 2 .B PR_SET_CHILD_SUBREAPER operation). .SH ERRORS @@ -48,7 +48,7 @@ and .BR getppid () wrapper functions transparently deal with this. See -.BR syscall (2) +.MR syscall 2 for details regarding register mapping. .SH STANDARDS POSIX.1-2008. @@ -64,12 +64,12 @@ with the goal of avoiding additional system calls when a process calls repeatedly. Normally this caching was invisible, but its correct operation relied on support in the wrapper functions for -.BR fork (2), -.BR vfork (2), +.MR fork 2 , +.MR vfork 2 , and -.BR clone (2): +.MR clone 2 : if an application bypassed the glibc wrappers for these system calls by using -.BR syscall (2), +.MR syscall 2 , then a call to .BR getpid () in the child would return the wrong value @@ -103,10 +103,10 @@ in the child would return the wrong value In addition, there were cases where .BR getpid () could return the wrong value even when invoking -.BR clone (2) +.MR clone 2 via the glibc wrapper function. (For a discussion of one such case, see BUGS in -.BR clone (2).) +.MR clone 2 .) Furthermore, the complexity of the caching code had been the source of a few bugs within glibc over the years. .P @@ -121,7 +121,7 @@ always invoke the actual system call, rather than returning a cached value. .\" Review progress of https://bugzilla.redhat.com/show_bug.cgi?id=1469757 .SH NOTES If the caller's parent is in a different PID namespace (see -.BR pid_namespaces (7)), +.MR pid_namespaces 7 ), .BR getppid () returns 0. .P @@ -131,20 +131,20 @@ is sometimes also known as the thread group ID (TGID). This contrasts with the kernel thread ID (TID), which is unique for each thread. For further details, see -.BR gettid (2) +.MR gettid 2 and the discussion of the .B CLONE_THREAD flag in -.BR clone (2). +.MR clone 2 . .SH SEE ALSO -.BR clone (2), -.BR fork (2), -.BR gettid (2), -.BR kill (2), -.BR exec (3), -.BR mkstemp (3), -.BR tempnam (3), -.BR tmpfile (3), -.BR tmpnam (3), -.BR credentials (7), -.BR pid_namespaces (7) +.MR clone 2 , +.MR fork 2 , +.MR gettid 2 , +.MR kill 2 , +.MR exec 3 , +.MR mkstemp 3 , +.MR tempnam 3 , +.MR tmpfile 3 , +.MR tmpnam 3 , +.MR credentials 7 , +.MR pid_namespaces 7 |