From c554b96722634d09cf8441fdac065efa4e1971c6 Mon Sep 17 00:00:00 2001 From: DTB Date: Mon, 29 Jul 2024 11:13:58 -0600 Subject: [PATCH] swab(1): fix type errors --- src/swab.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/swab.rs b/src/swab.rs index 771d352..dd63587 100644 --- a/src/swab.rs +++ b/src/swab.rs @@ -75,20 +75,20 @@ fn main() -> ExitCode { if let Err(e) = output.write(&right) .and_then(|_| output.write(&left)) { err(&argv[0], e); - break EX_IOERR // write error + break ExitCode::from(EX_IOERR as u8) // write error } }, Ok(v) => { // partial read; partially write if let Err(e) = output.write(&buf[..v]) { err(&argv[0], e); - break EX_IOERR // write error + break ExitCode::from(EX_IOERR as u8) // write error } }, Err(e) if e.kind() == ErrorKind::Interrupted && force => continue, Err(e) => { err(&argv[0], e); - break EX_IOERR // read error (or signal) + break ExitCode::from(EX_IOERR as u8) // read error (or signal) } } }