Age | Commit message (Collapse) | Author |
|
Previously, the `AioCb`'s `in_progress` field would erroneously be set
to `true`, even if the syscall had an error
Fixes #714
|
|
Printing a warning message to stderr isn't really appropriate, because
there's no way to guarantee that stderr is even valid. Nor is
aio_suspend necessarily an appropriate action to take.
|
|
These were exported for some weird reason and then left in
for documentation. Also some parts of certain modules used
them and others used the libc:: prefix. This was removed to
improve the docs and also code consistency
|
|
The existing AioCb constructors work for simple programs where
everything is stored on the stack. But in more complicated programs the
borrow checker can't prove that a buffer will outlive the AioCb that
references it. Fix this problem by introducting
AioCb::from_boxed_slice, which takes a reference-counted buffer.
Fixes #575
|
|
Also, fix style bug in AIO tests
|
|
|
|
If an AioCb has any in-kernel state, AioCb.drop will print a warning and
wait for it to complete.
|
|
Prevent immutable buffers from being used with aio_read or lio_listio
with LIO_READ. AioCb.from_slice no longer needs to be unsafe.
|
|
|
|
|
|
POSIX AIO is a standard for asynchronous file I/O. Read, write, and
fsync operations can all take place in the background, with completion
notification delivered by a signal, by a new thread, by kqueue, or not
at all. This commit supports all standard AIO functions. However,
lio_listio is disabled on macos because it doesn't seem to work, even
though the syscall is present.
The SigEvent class, used for AIO notifications among other things, is
also added.
Also, impl AsRef for TimeVal and TimeSpec
|