]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
prctl.2, PR_GET_CHILD_SUBREAPER.2const: Split PR_GET_CHILD_SUBREAPER from prctl(2)
authorAlejandro Colomar <alx@kernel.org>
Sun, 26 May 2024 16:12:13 +0000 (18:12 +0200)
committerAlejandro Colomar <alx@kernel.org>
Thu, 30 May 2024 13:31:15 +0000 (15:31 +0200)
Signed-off-by: Alejandro Colomar <alx@kernel.org>
man/man2/prctl.2
man/man2const/PR_GET_CHILD_SUBREAPER.2const [new file with mode: 0644]

index 2a6a43dad637d67946fae4e7c5a96a78f26e272b..2e6d9f4022e8a6c406eb138258de5f4108dd9f08 100644 (file)
@@ -31,7 +31,6 @@
 .\" 2012-10-25 Michael Kerrisk, Document PR_SET_TIMERSLACK and
 .\"                             PR_GET_TIMERSLACK
 .\" 2013-01-10 Kees Cook, document PR_SET_PTRACER
-.\" 2012-02-04 Michael Kerrisk, document PR_GET_CHILD_SUBREAPER
 .\" 2014-11-10 Dave Hansen, document PR_MPX_{EN,DIS}ABLE_MANAGEMENT
 .\"
 .\"
@@ -71,12 +70,8 @@ The first argument can be:
 .B PR_CAPBSET_DROP
 .TQ
 .B PR_SET_CHILD_SUBREAPER
-.\" prctl PR_GET_CHILD_SUBREAPER
-.TP
-.BR PR_GET_CHILD_SUBREAPER " (since Linux 3.4)"
-Return the "child subreaper" setting of the caller,
-in the location pointed to by
-.IR "(int\~*) arg2" .
+.TQ
+.B PR_GET_CHILD_SUBREAPER
 .\" prctl PR_SET_DUMPABLE
 .TP
 .BR PR_SET_DUMPABLE " (since Linux 2.3.20)"
@@ -2312,4 +2307,5 @@ glibc 2.0.6
 .BR PR_CAPBSET_READ (2const),
 .BR PR_CAPBSET_DROP (2const),
 .BR PR_SET_CHILD_SUBREAPER (2const),
+.BR PR_GET_CHILD_SUBREAPER (2const),
 .BR core (5)
diff --git a/man/man2const/PR_GET_CHILD_SUBREAPER.2const b/man/man2const/PR_GET_CHILD_SUBREAPER.2const
new file mode 100644 (file)
index 0000000..32052b8
--- /dev/null
@@ -0,0 +1,44 @@
+.\" Copyright 2012, 2013, 2015 Michael Kerrisk <mtk.manpages@gmail.com>
+.\"
+.\" SPDX-License-Identifier: Linux-man-pages-copyleft
+.\"
+.\" 2012-02-04 Michael Kerrisk, document PR_GET_CHILD_SUBREAPER
+.\"
+.TH PR_GET_CHILD_SUBREAPER 2const (date) "Linux man-pages (unreleased)"
+.SH NAME
+PR_GET_CHILD_SUBREAPER
+\-
+get the "child subreaper" attribute of the calling process
+.SH LIBRARY
+Standard C library
+.RI ( libc ", " \-lc )
+.SH SYNOPSIS
+.nf
+.B #include <sys/prctl.h>
+.P
+.BI "int prctl(int " op ", ..."
+.BI "          \fR/*\fP unsigned long " arg2 ", unsigned long " arg3 ,
+.BI "          unsigned long " arg4 ", unsigned long " arg5 " \fR*/\fP );"
+.fi
+.SH DESCRIPTION
+.TP
+.BR PR_GET_CHILD_SUBREAPER " (since Linux 3.4)"
+Return the "child subreaper" setting of the caller,
+in the location pointed to by
+.IR "(int\~*) arg2" .
+.SH RETURN VALUE
+On success,
+0 is returned.
+On error, \-1 is returned, and
+.I errno
+is set to indicate the error.
+.SH ERRORS
+.TP
+.B EFAULT
+.I arg2
+is an invalid address.
+.SH STANDARDS
+Linux.
+.SH HISTORY
+.SH SEE ALSO
+.BR prctl (2)