fix(windows): cmp vs. input type in result processor

This commit is contained in:
LGUG2Z
2022-04-25 08:15:13 -07:00
parent a10b13c799
commit d111d68c0b
2 changed files with 2 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
#![warn(clippy::all, clippy::nursery, clippy::pedantic)]
#![allow(clippy::missing_errors_doc)]
#![allow(clippy::missing_errors_doc, clippy::redundant_pub_crate)]
use std::collections::HashMap;
use std::fs::File;

View File

@@ -130,7 +130,7 @@ macro_rules! impl_process_windows_crate_integer_wrapper_result {
$(
impl ProcessWindowsCrateResult<$deref> for $input {
fn process(self) -> Result<$deref> {
if self.0 == 0 {
if self == $input(0) {
Err(std::io::Error::last_os_error().into())
} else {
Ok(self.0)