Make sure Error implements Send and Sync
This commit is contained in:
parent
4615d63b13
commit
58b72f9b0c
|
@ -14,8 +14,8 @@ use crate::response::ResponseStatus;
|
||||||
pub enum Error {
|
pub enum Error {
|
||||||
Io(std::io::Error),
|
Io(std::io::Error),
|
||||||
Command(ResponseStatus),
|
Command(ResponseStatus),
|
||||||
Xml(Box<dyn StdError>),
|
Xml(Box<dyn StdError + Send + Sync>),
|
||||||
Other(Box<dyn StdError>),
|
Other(Box<dyn StdError + Send + Sync>),
|
||||||
}
|
}
|
||||||
|
|
||||||
impl StdError for Error {}
|
impl StdError for Error {}
|
||||||
|
@ -33,8 +33,8 @@ impl Display for Error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl From<Box<dyn StdError>> for Error {
|
impl From<Box<dyn StdError + Send + Sync>> for Error {
|
||||||
fn from(e: Box<dyn StdError>) -> Self {
|
fn from(e: Box<dyn StdError + Send + Sync>) -> Self {
|
||||||
Self::Other(e)
|
Self::Other(e)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue