1 .\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
3 .\" SPDX-License-Identifier: GPL-2.0-or-later
5 .TH aio_cancel 3 (date) "Linux man-pages (unreleased)"
7 aio_cancel \- cancel an outstanding asynchronous I/O request
10 .RI ( librt ", " \-lrt )
15 .BI "int aio_cancel(int " fd ", struct aiocb *" aiocbp );
20 function attempts to cancel outstanding asynchronous I/O requests
21 for the file descriptor
25 is NULL, all such requests are canceled.
26 Otherwise, only the request
27 described by the control block pointed to by
32 for a description of the
36 Normal asynchronous notification occurs for canceled requests (see
40 The request return status
42 is set to \-1, and the request error status
46 The control block of requests that cannot be canceled is not changed.
48 If the request could not be canceled,
49 then it will terminate in the usual way after performing the I/O operation.
52 will return the status
59 differs from the file descriptor with which the asynchronous operation
60 was initiated, unspecified results occur.
62 Which operations are cancelable is implementation-defined.
63 .\" FreeBSD: not those on raw disk devices.
67 function returns one of the following values:
70 All requests were successfully canceled.
74 requests specified was not canceled because it was in progress.
75 In this case, one may check the status of individual requests using
79 All requests had already been completed before the call.
83 The cause of the error can be found by inspecting
89 is not a valid file descriptor.
97 function is available since glibc 2.1.
99 For an explanation of the terms used in this section, see
107 Interface Attribute Value
110 T} Thread safety MT-Safe
116 POSIX.1-2001, POSIX.1-2008.