Open System Services System Calls Reference Manual (G06.25+, H06.03+)

System Functions (r) readlink(2)
The current working directory is assigned from the VOLUME attribute of the Guardian
environment =_DEFAULTS DEFINE.
The use of static memory by the process increases slightly.
These effects occur only when the rst of the set of functions is called. The effects are not cumu-
lative.
RETURN VALUES
Upon successful completion, the readlink( ) function returns the number of characters placed in
the buffer (not including any terminating null). If the readlink() function fails, the buffer is not
modied, the value -1 is returned, and errno is set to indicate the error.
ERRORS
If any of the following conditions occurs, the readlink() function sets errno to the correspond-
ing value:
[EACCES] Search permission is denied on a component of the pathname prex of the path
parameter.
[EFAULT] The path parameter points outside the processs allocated address space.
[EFSBAD] The leset catalog for one of the lesets involved in the operation is corrupt.
[EINVAL] The le named by the path parameter is not a symbolic link.
[EIO] An I/O error occurred during a read from or write to the leset.
[ELOOP] There were too many links encountered in translating path.
[ENAMETOOLONG]
One of the following is too long:
The pathname pointed to by the path parameter
A component of the pathname pointed to by the path parameter
The intermediate result of pathname resolution when a symbolic link is
part of the path parameter
The pathconf( ) function can be called to obtain the applicable limits.
[ENOENT] One of the following conditions exists:
The le named by the path parameter does not exist.
The path parameter points to an empty string.
The path parameter species a le on a remote HP NonStop node but
communication with the remote node has been lost.
[ENOROOT] The root leset (leset 0) is not in the STARTED state.
[ENOTDIR] A component of the pathname prex of the path parameter is not a directory.
[ENXIO] An invalid device or address was specied during an input operation on a special
le. One of the following events occurred:
A device was specied that does not exist, or a request was made beyond
the limits of the device.
527186-003 Hewlett-Packard Company 67