1IO_DESTROY(2) Linux Programmer's Manual IO_DESTROY(2)
2
3
4
6 io_destroy - destroy an asynchronous I/O context
7
9 #include <libaio.h>
10
11 int io_destroy(aio_context_t ctx);
12
13 Link with -laio.
14
16 io_destroy() removes the asynchronous I/O context from the list of I/O
17 contexts and then destroys it. io_destroy() can also cancel any out‐
18 standing asynchronous I/O actions on ctx and block on completion.
19
21 On success, io_destroy() returns 0. For the failure return, see NOTES.
22
24 EFAULT The context pointed to is invalid.
25
26 EINVAL The AIO context specified by ctx is invalid.
27
28 ENOSYS io_destroy() is not implemented on this architecture.
29
31 The asynchronous I/O system calls first appeared in Linux 2.5, August
32 2002.
33
35 io_destroy() is Linux-specific and should not be used in programs that
36 are intended to be portable.
37
39 Glibc does not provide a wrapper function for this system call.
40
41 The wrapper provided in libaio for io_destroy() does not follow the
42 usual C library conventions for indicating error: on error it returns a
43 negated error number (the negative of one of the values listed in
44 ERRORS). If the system call is invoked via syscall(2), then the return
45 value follows the usual conventions for indicating an error: -1, with
46 errno set to a (positive) value that indicates the error.
47
49 io_cancel(2), io_getevents(2), io_setup(2), io_submit(2)
50
52 This page is part of release 3.22 of the Linux man-pages project. A
53 description of the project, and information about reporting bugs, can
54 be found at http://www.kernel.org/doc/man-pages/.
55
56
57
58Linux 2008-06-18 IO_DESTROY(2)