summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2014-01-03 15:35:24 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2014-01-03 15:35:24 +0000
commitc460e7b70f5936825e7cd27ec1f068e7ea5f5abb (patch)
treecd2819447fb3bbc4942b81086f9d0e2d99afce42
parent135d1d914dba7d441473e68c3238d45c10dd4571 (diff)
some more information, based on a diff by sven falempin
-rw-r--r--lib/libpthread/man/pthread_mutex_init.313
1 files changed, 10 insertions, 3 deletions
diff --git a/lib/libpthread/man/pthread_mutex_init.3 b/lib/libpthread/man/pthread_mutex_init.3
index 5567248184b..a4f66a37628 100644
--- a/lib/libpthread/man/pthread_mutex_init.3
+++ b/lib/libpthread/man/pthread_mutex_init.3
@@ -1,4 +1,4 @@
-.\" $OpenBSD: pthread_mutex_init.3,v 1.12 2013/06/05 03:44:50 tedu Exp $
+.\" $OpenBSD: pthread_mutex_init.3,v 1.13 2014/01/03 15:35:23 tedu Exp $
.\"
.\" Copyright (c) 1997 Brian Cully <shmit@kublai.com>
.\" All rights reserved.
@@ -29,7 +29,7 @@
.\"
.\" $FreeBSD: pthread_mutex_init.3,v 1.6 1999/08/28 00:03:07 peter Exp $
.\"
-.Dd $Mdocdate: June 5 2013 $
+.Dd $Mdocdate: January 3 2014 $
.Dt PTHREAD_MUTEX_INIT 3
.Os
.Sh NAME
@@ -48,7 +48,13 @@ If
.Fa attr
is
.Dv NULL
-the default attributes are used.
+the default attributes are used, otherwise
+.Fa attr
+should be initialized by calling
+.Xr pthread_mutexattr_init 3 .
+.Pp
+A mutex may also be initialized by assignment with the macro
+PTHREAD_MUTEX_INITIALIZER.
.Sh RETURN VALUES
If successful,
.Fn pthread_mutex_init
@@ -67,6 +73,7 @@ is invalid.
The process cannot allocate enough memory to create another mutex.
.El
.Sh SEE ALSO
+.Xr pthread_mutexattr_init 3 ,
.Xr pthread_mutex_destroy 3 ,
.Xr pthread_mutex_lock 3 ,
.Xr pthread_mutex_unlock 3