summaryrefslogtreecommitdiff
path: root/lib/libc/stdlib
diff options
context:
space:
mode:
authorKurt Miller <kurt@cvs.openbsd.org>2008-04-04 19:30:42 +0000
committerKurt Miller <kurt@cvs.openbsd.org>2008-04-04 19:30:42 +0000
commit2419060533a4e33e9985400be7adb6ab4ce3263b (patch)
tree7a2a9df18a429efb139fadf314d6b2368bde2e4e /lib/libc/stdlib
parenta56291bdcb56c4ec3dbbb489004badcd40f4c656 (diff)
- do not call pthread_atfork(3) handlers when a multithreaded program
calls vfork(2). "untested, but looks OK" marc@ - document vfork(2), popen(3) and system(3) don't call atfork handlers in multithreaded programs. okay jmc@
Diffstat (limited to 'lib/libc/stdlib')
-rw-r--r--lib/libc/stdlib/system.39
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/libc/stdlib/system.3 b/lib/libc/stdlib/system.3
index 338d3bfa835..a49e595bc0a 100644
--- a/lib/libc/stdlib/system.3
+++ b/lib/libc/stdlib/system.3
@@ -29,9 +29,9 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $OpenBSD: system.3,v 1.10 2007/05/31 19:19:32 jmc Exp $
+.\" $OpenBSD: system.3,v 1.11 2008/04/04 19:30:41 kurt Exp $
.\"
-.Dd $Mdocdate: May 31 2007 $
+.Dd $Mdocdate: April 4 2008 $
.Dt SYSTEM 3
.Os
.Sh NAME
@@ -66,6 +66,11 @@ Otherwise,
.Fn system
returns the termination status of the shell in the format specified by
.Xr waitpid 2 .
+.Pp
+Note that fork handlers established using
+.Xr pthread_atfork 3
+are not called when a multithreaded program calls
+.Fn system .
.Sh RETURN VALUES
If a child process cannot be created, or the termination status of
the shell cannot be obtained,