diff --git a/telos/src/raw.rs b/telos/src/raw.rs index cfd5cc6..e1aa3cc 100644 --- a/telos/src/raw.rs +++ b/telos/src/raw.rs @@ -60,11 +60,11 @@ impl Error for TlsError { &self.msg } } -/// Convert TlsError to io::Error, use WouldBlock if applicable +/// Convert TlsError to io::Error, use std::io::ErrorKindInterrupted if applicable impl convert::From for io::Error { fn from(err: TlsError) -> Self { match err.code { - ffi::WANT_POLLIN | ffi::WANT_POLLOUT => io::Error::new(io::ErrorKind::WouldBlock, err), + ffi::WANT_POLLIN | ffi::WANT_POLLOUT => io::Error::new(io::ErrorKind::Interrupted, err), _ => io::Error::new(io::ErrorKind::Other, err.msg), } }