use io::Error::other

This commit is contained in:
cy 2025-04-28 11:11:46 -04:00
parent 9d2e9e38bd
commit 7285c29e88

View file

@ -150,10 +150,7 @@ impl Stream for AsyncWriteAdapter {
match message {
Data(v) => Poll::Ready(Some(Ok(v.into()))),
Error(exception) => {
let error = std::io::Error::new(
io::ErrorKind::Other,
format!("cxx error: {exception}"),
);
let error = std::io::Error::other(format!("cxx error: {exception}"));
Poll::Ready(Some(Err(error)))
}
Eof => {