Loading...
--- Libc/Libc-498/sys/sem_open.2
+++ Libc/Libc-391/sys/sem_open.2
@@ -29,24 +29,17 @@
.Sh SYNOPSIS
.Fd #include <semaphore.h>
.Ft sem_t *
-.Fo sem_open
-.Fa "const char *name"
-.Fa "int oflag"
-.Fa "..."
-.Fc
-.Pp
-The parameters "mode_t mode" and "unsigned int value"
-are optional.
+.Fn sem_open "const char *name" "int flags"
+.Ft sem_t *
+.Fn sem_open "const char *name" "int flags" "mode_t mode" "unsigned int value"
.Sh DESCRIPTION
The named semaphore named
.Fa name
is initialized and opened as specified by the argument
-.Fa oflag
+.Fa flags
and a semaphore descriptor is returned to the calling process.
.Pp
-The value of
-.Fa oflag
-is formed by
+The flags specified are formed by
.Em or Ns 'ing
the following values:
.Pp
@@ -56,8 +49,8 @@
.Ed
.Pp
If
-.Dv O_CREAT
-is specified,
+.Dv O_CREATE
+if specified,
.Fn sem_open
requires an additional two arguments.
.Fa mode
@@ -84,7 +77,7 @@
set.
.Pp
When a new semaphore is created, it is given the user ID and group ID
-which correspond to the effective user and group IDs of the calling
+which coorespond to the effective user and group IDs of the calling
process. There is no visible entry in the file system for the created
object in this implementation.
.Pp
@@ -155,14 +148,14 @@
space available to create the semaphore.
.El
.Sh SEE ALSO
+.Xr semctl 2 ,
+.Xr semget 2 ,
+.Xr semop 2 ,
.Xr sem_close 2 ,
.Xr sem_post 2 ,
.Xr sem_trywait 2 ,
.Xr sem_unlink 2 ,
.Xr sem_wait 2 ,
-.Xr semctl 2 ,
-.Xr semget 2 ,
-.Xr semop 2 ,
.Xr umask 2
.Sh HISTORY
.Fn sem_open