1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-30 20:47:46 +00:00

Ignore two question-mark warnings

This commit is contained in:
Sylvestre Ledru 2021-10-23 20:59:19 +02:00
parent f28da04fc5
commit a5bc2211d5

View file

@ -461,6 +461,8 @@ fn standard(mut paths: Vec<String>, b: Behavior) -> UResult<()> {
return Err(InstallError::CreateDirFailed(parent.to_path_buf(), e).into()); return Err(InstallError::CreateDirFailed(parent.to_path_buf(), e).into());
} }
// Silent the warning as we want to the error message
#[allow(clippy::question_mark)]
if mode::chmod(parent, b.mode()).is_err() { if mode::chmod(parent, b.mode()).is_err() {
return Err(InstallError::ChmodFailed(parent.to_path_buf()).into()); return Err(InstallError::ChmodFailed(parent.to_path_buf()).into());
} }
@ -583,6 +585,8 @@ fn copy(from: &Path, to: &Path, b: &Behavior) -> UResult<()> {
} }
} }
// Silent the warning as we want to the error message
#[allow(clippy::question_mark)]
if mode::chmod(to, b.mode()).is_err() { if mode::chmod(to, b.mode()).is_err() {
return Err(InstallError::ChmodFailed(to.to_path_buf()).into()); return Err(InstallError::ChmodFailed(to.to_path_buf()).into());
} }