Open System Services Library Calls Reference Manual (G06.27+, H06.04+)

getcwd(3) OSS Library Calls Reference Manual
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, either the buffer parameter or, if buffer was a null pointer, a pointer
to a buffer is returned. Otherwise, a null value is returned and errno is set to indicate the error.
In that case, the contents of the buffer pointed to by buffer (if not a null pointer) is undened.
ERRORS
If any of the following conditions occurs, the getcwd() function sets errno to the corresponding
value:
[EACCES] The requested current working directory is not found because search (execute) or
read permission is denied for a component of the current working directory path-
name.
[ECWDTOOLONG]
The length of the pathname, or a component of the pathname, is too long. Use
the pathconf() function to obtain the applicable system limits.
[EFAULT] The buffer parameter is an invalid address.
[EFSBAD] The program attempted an operation involving a leset with a corrupted leset
catalog.
[EINVAL] The size parameter is 0 (zero).
[ENOCRE] The process is not compliant with the Common Run-Time Environment (CRE)
and the value of the buffer parameter is a null pointer.
[ENOENT] The requested current working directory is not found, because it does not exist.
[ENOMEM] The requested amount of memory could not be allocated and the value of the
buffer parameter is a null pointer.
[ENOROOT] The program attempted an operation while the root leset was unavailable.
[ENXIO] No such device or address. An invalid device or address was specied during an
input or output 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.
The leset containing the requestors current working directory or root
directory is not mounted. This error can occur after failure and restart of
an OSS name server until the leset has been repaired and remounted.
[EOSSNOTRUNNING]
The program attempted an operation on an object in the OSS environment while
a required system process was not running.
320 Hewlett-Packard Company 527187-004