]> git.ipfire.org Git - thirdparty/man-pages.git/blob - man3/aio_return.3
Many pages: Use correct letter case in page titles (TH)
[thirdparty/man-pages.git] / man3 / aio_return.3
1 .\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
2 .\"
3 .\" SPDX-License-Identifier: GPL-2.0-or-later
4 .\"
5 .TH aio_return 3 (date) "Linux man-pages (unreleased)"
6 .SH NAME
7 aio_return \- get return status of asynchronous I/O operation
8 .SH LIBRARY
9 Real-time library
10 .RI ( librt ", " \-lrt )
11 .SH SYNOPSIS
12 .nf
13 .B "#include <aio.h>"
14 .PP
15 .BI "ssize_t aio_return(struct aiocb *" aiocbp );
16 .fi
17 .SH DESCRIPTION
18 The
19 .BR aio_return ()
20 function returns the final return status for the asynchronous I/O request
21 with control block pointed to by
22 .IR aiocbp .
23 (See
24 .BR aio (7)
25 for a description of the
26 .I aiocb
27 structure.)
28 .PP
29 This function should be called only once for any given request, after
30 .BR aio_error (3)
31 returns something other than
32 .BR EINPROGRESS .
33 .SH RETURN VALUE
34 If the asynchronous I/O operation has completed, this function returns
35 the value that would have been returned in case of a synchronous
36 .BR read (2),
37 .BR write (2),
38 .BR fsync (2),
39 or
40 .BR fdatasync (2),
41 call.
42 On error, \-1 is returned, and \fIerrno\fP is set to indicate the error.
43 .PP
44 If the asynchronous I/O operation has not yet completed,
45 the return value and effect of
46 .BR aio_return ()
47 are undefined.
48 .SH ERRORS
49 .TP
50 .B EINVAL
51 .I aiocbp
52 does not point at a control block for an asynchronous I/O request
53 of which the return status has not been retrieved yet.
54 .TP
55 .B ENOSYS
56 .BR aio_return ()
57 is not implemented.
58 .SH VERSIONS
59 The
60 .BR aio_return ()
61 function is available since glibc 2.1.
62 .SH ATTRIBUTES
63 For an explanation of the terms used in this section, see
64 .BR attributes (7).
65 .ad l
66 .nh
67 .TS
68 allbox;
69 lbx lb lb
70 l l l.
71 Interface Attribute Value
72 T{
73 .BR aio_return ()
74 T} Thread safety MT-Safe
75 .TE
76 .hy
77 .ad
78 .sp 1
79 .SH STANDARDS
80 POSIX.1-2001, POSIX.1-2008.
81 .SH EXAMPLES
82 See
83 .BR aio (7).
84 .SH SEE ALSO
85 .BR aio_cancel (3),
86 .BR aio_error (3),
87 .BR aio_fsync (3),
88 .BR aio_read (3),
89 .BR aio_suspend (3),
90 .BR aio_write (3),
91 .BR lio_listio (3),
92 .BR aio (7)