summaryrefslogtreecommitdiff
path: root/test/sys/test_lio_listio_resubmit.rs
diff options
context:
space:
mode:
Diffstat (limited to 'test/sys/test_lio_listio_resubmit.rs')
-rw-r--r--test/sys/test_lio_listio_resubmit.rs9
1 files changed, 4 insertions, 5 deletions
diff --git a/test/sys/test_lio_listio_resubmit.rs b/test/sys/test_lio_listio_resubmit.rs
index 1c1941fb..c9077891 100644
--- a/test/sys/test_lio_listio_resubmit.rs
+++ b/test/sys/test_lio_listio_resubmit.rs
@@ -4,7 +4,6 @@
// we must disable the test here rather than in Cargo.toml
#![cfg(target_os = "freebsd")]
-use nix::Error;
use nix::errno::*;
use nix::libc::off_t;
use nix::sys::aio::*;
@@ -25,7 +24,7 @@ fn finish_liocb(liocb: &mut LioCb) {
let e = liocb.error(j);
match e {
Ok(()) => break,
- Err(Error(Errno::EINPROGRESS)) =>
+ Err(Errno::EINPROGRESS) =>
thread::sleep(time::Duration::from_millis(10)),
Err(x) => panic!("aio_error({:?})", x)
}
@@ -82,9 +81,9 @@ fn test_lio_listio_resubmit() {
}
let mut liocb = builder.finish();
let mut err = liocb.listio(LioMode::LIO_NOWAIT, SigevNotify::SigevNone);
- while err == Err(Error(Errno::EIO)) ||
- err == Err(Error(Errno::EAGAIN)) ||
- err == Err(Error(Errno::EINTR)) {
+ while err == Err(Errno::EIO) ||
+ err == Err(Errno::EAGAIN) ||
+ err == Err(Errno::EINTR) {
//
thread::sleep(time::Duration::from_millis(10));
resubmit_count += 1;