1
0
Fork 0
forked from wry/wry

all: use run-on-drop crate

This commit is contained in:
Julian Orth 2026-02-13 11:09:07 +01:00
parent 346c6a7345
commit 0932ad11b5
19 changed files with 60 additions and 110 deletions

View file

@ -9,8 +9,8 @@ use {
sys::{IORING_OP_READ, IORING_OP_WRITE, io_uring_sqe},
},
time::Time,
utils::on_drop::OnDrop,
},
run_on_drop::on_drop,
uapi::{Fd, c},
};
@ -86,7 +86,7 @@ impl IoUring {
self.schedule_timeout_link(time);
}
}
let panic = OnDrop(|| panic!("Operation cannot be cancelled from userspace"));
let panic = on_drop(|| panic!("Operation cannot be cancelled from userspace"));
cancel(id.id);
let res = Ok(pr.await.map(|v| v as usize)).merge();
panic.forget();