]>
Commit | Line | Data |
---|---|---|
fea681da MK |
1 | .\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl) |
2 | .\" | |
e4a74ca8 | 3 | .\" SPDX-License-Identifier: GPL-2.0-or-later |
fea681da | 4 | .\" |
45186a5d | 5 | .TH AIO_ERROR 3 2021-03-22 "Linux man-pages (unreleased)" |
fea681da MK |
6 | .SH NAME |
7 | aio_error \- get error status of asynchronous I/O operation | |
a42212d0 AC |
8 | .SH LIBRARY |
9 | Real-time library | |
8fc3b2cf | 10 | .RI ( librt ", " \-lrt ) |
fea681da | 11 | .SH SYNOPSIS |
c7db92b9 | 12 | .nf |
fea681da | 13 | .B "#include <aio.h>" |
68e4db0a | 14 | .PP |
fea681da | 15 | .BI "int aio_error(const struct aiocb *" aiocbp ); |
c7db92b9 | 16 | .fi |
fea681da MK |
17 | .SH DESCRIPTION |
18 | The | |
e511ffb6 | 19 | .BR aio_error () |
fea681da MK |
20 | function returns the error status for the asynchronous I/O request |
21 | with control block pointed to by | |
22 | .IR aiocbp . | |
2b014d76 MK |
23 | (See |
24 | .BR aio (7) | |
25 | for a description of the | |
26 | .I aiocb | |
27 | structure.) | |
47297adb | 28 | .SH RETURN VALUE |
ba9e24aa MK |
29 | This function returns one of the following: |
30 | .IP * 3 | |
31 | .BR EINPROGRESS , | |
1274071a | 32 | if the request has not been |
c13182ef | 33 | completed yet. |
ba9e24aa MK |
34 | .IP * |
35 | .BR ECANCELED , | |
1274071a | 36 | if the request was canceled. |
ba9e24aa MK |
37 | .IP * |
38 | 0, if the request completed successfully. | |
39 | .IP * | |
e19783f5 | 40 | A positive error number, if the asynchronous I/O operation failed. |
ba9e24aa | 41 | This is the same value that would have been stored in the |
fea681da | 42 | .I errno |
ba9e24aa MK |
43 | variable in the case of a synchronous |
44 | .BR read (2), | |
45 | .BR write (2), | |
46 | .BR fsync (2), | |
fea681da | 47 | or |
ba9e24aa MK |
48 | .BR fdatasync (2) |
49 | call. | |
fea681da MK |
50 | .SH ERRORS |
51 | .TP | |
52 | .B EINVAL | |
53 | .I aiocbp | |
54 | does not point at a control block for an asynchronous I/O request | |
55 | of which the return status (see | |
56 | .BR aio_return (3)) | |
57 | has not been retrieved yet. | |
aea038d6 MK |
58 | .TP |
59 | .B ENOSYS | |
60 | .BR aio_error () | |
61 | is not implemented. | |
793514ae MK |
62 | .SH VERSIONS |
63 | The | |
64 | .BR aio_error () | |
65 | function is available since glibc 2.1. | |
34a8bc85 | 66 | .SH ATTRIBUTES |
37e166e8 MK |
67 | For an explanation of the terms used in this section, see |
68 | .BR attributes (7). | |
c466875e MK |
69 | .ad l |
70 | .nh | |
37e166e8 MK |
71 | .TS |
72 | allbox; | |
c466875e | 73 | lbx lb lb |
37e166e8 MK |
74 | l l l. |
75 | Interface Attribute Value | |
76 | T{ | |
34a8bc85 | 77 | .BR aio_error () |
37e166e8 MK |
78 | T} Thread safety MT-Safe |
79 | .TE | |
c466875e MK |
80 | .hy |
81 | .ad | |
82 | .sp 1 | |
3113c7f3 | 83 | .SH STANDARDS |
793514ae | 84 | POSIX.1-2001, POSIX.1-2008. |
a14af333 | 85 | .SH EXAMPLES |
b44bee16 MK |
86 | See |
87 | .BR aio (7). | |
47297adb | 88 | .SH SEE ALSO |
fea681da MK |
89 | .BR aio_cancel (3), |
90 | .BR aio_fsync (3), | |
91 | .BR aio_read (3), | |
92 | .BR aio_return (3), | |
93 | .BR aio_suspend (3), | |
25fa6c3d | 94 | .BR aio_write (3), |
cd587df6 | 95 | .BR lio_listio (3), |
25fa6c3d | 96 | .BR aio (7) |