Fix clippy lints (#2768)

This commit is contained in:
Casey Rodarmor 2025-06-06 12:32:32 -07:00 committed by GitHub
parent 515e806b51
commit 0093ae9488
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 8 deletions

View file

@ -108,10 +108,7 @@ impl TryFrom<u8> for Signal {
2 => Ok(Signal::Interrupt),
3 => Ok(Signal::Quit),
15 => Ok(Signal::Terminate),
_ => Err(io::Error::new(
io::ErrorKind::Other,
format!("unexpected signal: {n}"),
)),
_ => Err(io::Error::other(format!("unexpected signal: {n}"))),
}
}
}

View file

@ -123,10 +123,7 @@ impl SignalHandler {
let pid = match child.id().try_into() {
Err(err) => {
return (
Err(io::Error::new(
io::ErrorKind::Other,
format!("invalid child PID: {err}"),
)),
Err(io::Error::other(format!("invalid child PID: {err}"))),
None,
)
}