summaryrefslogtreecommitdiffstats
path: root/lib/libc/sys/open.2
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2007-01-07 17:55:19 +0000
committerpjd <pjd@FreeBSD.org>2007-01-07 17:55:19 +0000
commitef0342d7a830c78f52d078e8bf8b4d4cb471a1fb (patch)
tree3d8186e3e6284afb1585e3350c9e96e96637be65 /lib/libc/sys/open.2
parent39a9779535fa3d6e03f70d09cd9a766cfbbd5b42 (diff)
downloadFreeBSD-src-ef0342d7a830c78f52d078e8bf8b4d4cb471a1fb.zip
FreeBSD-src-ef0342d7a830c78f52d078e8bf8b4d4cb471a1fb.tar.gz
- POSIX mentions that EACCES can be returned when O_TRUNC is specified
separately. Do the same. - Document when EPERM can be returned.
Diffstat (limited to 'lib/libc/sys/open.2')
-rw-r--r--lib/libc/sys/open.219
1 files changed, 18 insertions, 1 deletions
diff --git a/lib/libc/sys/open.2 b/lib/libc/sys/open.2
index e56ddc0..51ea571 100644
--- a/lib/libc/sys/open.2
+++ b/lib/libc/sys/open.2
@@ -32,7 +32,7 @@
.\" @(#)open.2 8.2 (Berkeley) 11/16/93
.\" $FreeBSD$
.\"
-.Dd January 10, 2006
+.Dd January 7, 2007
.Dt OPEN 2
.Os
.Sh NAME
@@ -229,11 +229,28 @@ Search permission is denied for a component of the path prefix.
The required permissions (for reading and/or writing)
are denied for the given flags.
.It Bq Er EACCES
+.Dv O_TRUNC
+is specified and write permission is denied.
+.It Bq Er EACCES
.Dv O_CREAT
is specified,
the file does not exist,
and the directory in which it is to be created
does not permit writing.
+.It Bq Er EPERM
+.Dv O_CREAT
+is specified, the file does not exist, and the directory in which it is to be
+created has its immutable flag set, see the
+.Xr chflags 2
+manual page for more information.
+.It Bq Er EPERM
+.Dv The named file has its immutable flag set and the file is to be modified.
+.It Bq Er EPERM
+.Dv The named file has its append-only flag set, the file is to be modified, and
+.Dv O_TRUNC
+is specified or
+.Dv O_APPEND
+is not specified.
.It Bq Er ELOOP
Too many symbolic links were encountered in translating the pathname.
.It Bq Er EISDIR
OpenPOWER on IntegriCloud