NAME
chmod - change mode of satellite file
SYNOPSIS
chmod (path, mode)
char *path;
int mode;
DESCRIPTION
path
points to the path name of a file.
chmod
changes the access permissions of the files according to
mode
, and octal number constructed from the OR of the following:
-
04 read
-
02 write
-
01 execute
chmod
will fail and the file mode will be unchanged if one or more of the
following are true:
-
The path name specifies a directory or a file that does not
exist. [ENOENT]
-
The path name points to a directory, not a file. [EISDIR]
-
The path name points to a file on the host. [EACCES]
RETURN VALUE
On successful completion, a value of 0 is returned. Otherwise, a
value of -1 is returned and
errno
is set to indicate the error.
SEE ALSO
chsize(2F)
,
create(2F)