cc [ flag ... ] file ... -laio [ library ... ]
#include <sys/asynch.h>
int aiocancel(aio_result_t *resultp);
Unsafe
aiocancel() cancels the asynchronous operation associated with the result buffer pointed to by resultp. It may not be possible to immediately cancel an operation which is in progress and in this case, aiocancel() will not wait to cancel it.
Upon successful completion, aiocancel() returns 0 and the requested operation is cancelled. The application will not receive the SIGIO completion signal for an asynchronous operation that is successfully cancelled.
aiocancel() returns:
aiocancel() will fail if any of the following are true: