1 .\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
3 .\" %%%LICENSE_START(GPLv2+_DOC_FULL)
4 .\" This is free documentation; you can redistribute it and/or
5 .\" modify it under the terms of the GNU General Public License as
6 .\" published by the Free Software Foundation; either version 2 of
7 .\" the License, or (at your option) any later version.
9 .\" The GNU General Public License's references to "object code"
10 .\" and "executables" are to be interpreted as the output of any
11 .\" document formatting or typesetting system, including
12 .\" intermediate and printed output.
14 .\" This manual is distributed in the hope that it will be useful,
15 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
16 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 .\" GNU General Public License for more details.
19 .\" You should have received a copy of the GNU General Public
20 .\" License along with this manual; if not, see
21 .\" <http://www.gnu.org/licenses/>.
24 .TH AIO_CANCEL 3 2015-03-02 "" "Linux Programmer's Manual"
26 aio_cancel \- cancel an outstanding asynchronous I/O request
30 .BI "int aio_cancel(int " fd ", struct aiocb *" aiocbp );
32 Link with \fI\-lrt\fP.
36 function attempts to cancel outstanding asynchronous I/O requests
37 for the file descriptor
41 is NULL, all such requests are canceled.
42 Otherwise, only the request
43 described by the control block pointed to by
48 for a description of the
52 Normal asynchronous notification occurs for canceled requests (see
56 The request return status
58 is set to \-1, and the request error status
62 The control block of requests that cannot be canceled is not changed.
64 If the request could not be canceled,
65 then it will terminate in the usual way after performing the I/O operation.
68 will return the status
75 differs from the file descriptor with which the asynchronous operation
76 was initiated, unspecified results occur.
78 Which operations are cancelable is implementation-defined.
79 .\" FreeBSD: not those on raw disk devices.
83 function returns one of the following values:
86 All requests were successfully canceled.
90 requests specified was not canceled because it was in progress.
91 In this case, one may check the status of individual requests using
95 All requests had already been completed before the call.
99 The cause of the error can be found by inspecting
105 is not a valid file descriptor.
113 function is available since glibc 2.1.
115 For an explanation of the terms used in this section, see
121 Interface Attribute Value
124 T} Thread safety MT-Safe
127 POSIX.1-2001, POSIX.1-2008.