CLOSE(2) — HP-UX
NAME
close − close a file descriptor
SYNOPSIS
int close (fildes)
int fildes;
DESCRIPTION
Fildes is a file descriptor obtained from a creat, open, dup, fcntl, or pipe system call. Close closes the file descriptor indicated by fildes. All associated file segments which have been locked by this process with the lockf function are released (i.e., unlocked).
ERRORS
[EBADF] Close will fail if fildes is not a valid open file descriptor.
RETURN VALUE
Upon 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
creat(2), dup(2), exec(2), fcntl(2), lockf(2), open(2), pipe(2).
Hewlett-Packard Company — May 11, 2021