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

Merge pull request #2724 from sylvestre/silent-a-warning-2

Ignore two question-mark warnings
This commit is contained in:
Sylvestre Ledru 2021-10-23 23:46:59 +02:00 committed by GitHub
commit 995826e4a2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

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());
}
// Silent the warning as we want to the error message
#[allow(clippy::question_mark)]
if mode::chmod(parent, b.mode()).is_err() {
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() {
return Err(InstallError::ChmodFailed(to.to_path_buf()).into());
}