Use wiggle "trappable error" to implement wasi-common (#5279)
* convert wasi-common from defining its own error to using wiggle trappable error * wasi-common impl crates: switch error strategy * wasmtime-wasi: error is trappable, and no longer requires UserErrorConversion * docs * typo * readdir: windows fixes * fix windows scheduler errors fun fact! the Send and Recv errors here that just had a `.context` on them were previously not being captured in the downcasting either. They need to be traps, and would have ended up that way by ommission, but you'd never actually know that by reading the code!
This commit is contained in:
@@ -47,7 +47,7 @@ pub async fn poll_oneoff<'a>(poll: &mut Poll<'a>) -> Result<(), Error> {
|
||||
match rustix::io::poll(&mut pollfds, poll_timeout) {
|
||||
Ok(ready) => break ready,
|
||||
Err(rustix::io::Errno::INTR) => continue,
|
||||
Err(err) => return Err(err.into()),
|
||||
Err(err) => return Err(std::io::Error::from(err).into()),
|
||||
}
|
||||
};
|
||||
if ready > 0 {
|
||||
|
||||
Reference in New Issue
Block a user