diff --git a/src/error.rs b/src/error.rs index 7495bd3..9a0e01f 100644 --- a/src/error.rs +++ b/src/error.rs @@ -16,7 +16,7 @@ pub enum Error { UnconsumedInput(String), /// The string is the input at which the error was encountered. ParsingError(String, ParsingErrorKind), - PeParsingError(PathBuf, Box), + PeParsingError(PathBuf, Box), IoError(PathBuf, io::Error), } diff --git a/src/function/version.rs b/src/function/version.rs index 0d3dc40..412d36f 100644 --- a/src/function/version.rs +++ b/src/function/version.rs @@ -150,7 +150,7 @@ impl Version { match get_pe_version_info(file_map.as_ref()) { Ok(v) => Ok(formatter(&v).map(Version::from)), Err(FindError::NotFound) => Ok(None), - Err(e) => Err(Error::PeParsingError(file_path.to_path_buf(), e.into())), + Err(e) => Err(Error::PeParsingError(file_path.to_path_buf(), Box::new(e))), } } }