1
0
Files
irix-657m-src/eoe/man/man3/aio_error.3
2022-09-29 17:59:04 +03:00

62 lines
1.7 KiB
Groff

'\"macro stdmacro
.TH AIO_ERROR 3
.SH NAME
aio_error, aio_error64 \- return error status of an asynchronous I/O operation
.Op c p a
.SH C SYNOPSIS
.nf
.B #include <aio.h>
.PP
.B "int aio_error(const aiocb_t *aiocbp);
.PP
.B "int aio_error64(const aiocb64_t *aiocbp);
.fi
.PP
.Op
.SH DESCRIPTION
.PP
The
.I aio_error()
function returns the error status associated with the
.I aiocbp
passed in. The error status for an asynchronous I/O operation is the
.I errno
value that would be set by the corresponding
.I read(2)
or
.I write(2)
or
.I fsync(2)
operation.
If the operation has not yet completed, then the error status shall be equal to EINPROGRESS.
.P
The \f2aio_error64\f1() function is identical to \f2aio_error\f1() except
that it takes an \f2aiocb64_t\f1 * (see <\f3aio.h\f1>).
This structure allows for the specification of a file offset greater than
2 Gigabytes.
The user must define \f3_ABI_SOURCE\f1 and include \f3-labi\f1 to
access the \f2aio64\f1 routines.
.SH "SEE ALSO"
aio_read(3), aio_write(3), lio_listio(3), aio_error(3), aio_return(3), aio_cancel(3), aio_sgi_init(3), read(2), lseek(2), close(2),_exit(2), exec(2), fork(2).
.SH "DIAGNOSTICS"
.PP
If the asynchronous I/O operation has completed successfully, then 0 shall be returned. If the asynchronous operation has completed unsuccessfully, then the error status, as described for
.I read(2),
.I write(2),
and
.I fsync(2)
shall be returned. If the asynchronous I/O has not yet completed, then EINPROGRESS shall be returned.
.sp
If any of the conditions below occur, the
.I aio_error()
function shall return -1 and set
.I errno
to the corresponding value.
.TP 15
.SM
\%[EINVAL]
The
.I aiocbp
argument does not yet refer to an asynchronous operation whose return status has not yet been retrieved.