diff options
Diffstat (limited to 'lib/libc/sys/chown.2')
-rw-r--r-- | lib/libc/sys/chown.2 | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/libc/sys/chown.2 b/lib/libc/sys/chown.2 index 3b194b6d33c..d21a1e32c67 100644 --- a/lib/libc/sys/chown.2 +++ b/lib/libc/sys/chown.2 @@ -1,4 +1,4 @@ -.\" $OpenBSD: chown.2,v 1.3 1997/01/26 05:10:33 downsj Exp $ +.\" $OpenBSD: chown.2,v 1.4 1999/02/27 21:56:10 deraadt Exp $ .\" $NetBSD: chown.2,v 1.10 1995/10/12 15:40:47 jtc Exp $ .\" .\" Copyright (c) 1980, 1991, 1993, 1994 @@ -69,19 +69,19 @@ but the change .Fa owner capability is restricted to the super-user. .Pp -.Fn Chown +.Fn chown clears the set-user-id and set-group-id bits on the file to prevent accidental or mischievous creation of set-user-id and set-group-id programs. .Pp -.Fn Lchown +.Fn lchown operates similarly to how .Fn chown operated on older systems, and does not follow symbolic links. It allows the owner and group of a symbolic link to be set. .Pp -.Fn Fchown +.Fn fchown is particularly useful when used in conjunction with the file locking primitives (see .Xr flock 2 ) . @@ -94,7 +94,7 @@ Zero is returned if the operation was successful; error code being placed in the global variable .Va errno . .Sh ERRORS -.Fn Chown +.Fn chown or .Fn lchown will fail and the file or link will be unchanged if: @@ -118,20 +118,20 @@ The effective user ID is not the super-user. .It Bq Er EROFS The named file resides on a read-only file system. .It Bq Er EFAULT -.Fa Path +.Fa path points outside the process's allocated address space. .It Bq Er EIO An I/O error occurred while reading from or writing to the file system. .El .Pp -.Fn Fchown +.Fn fchown will fail if: .Bl -tag -width Er .It Bq Er EBADF -.Fa Fd +.Fa fd does not refer to a valid descriptor. .It Bq Er EINVAL -.Fa Fd +.Fa fd refers to a socket, not a file. .It Bq Er EPERM The effective user ID is not the super-user. |