mirror of
https://github.com/uutils/coreutils
synced 2024-12-18 09:03:14 +00:00
cat: fixed indentation
This commit is contained in:
parent
0d56009c3a
commit
6d13bcf2da
1 changed files with 8 additions and 9 deletions
|
@ -231,15 +231,14 @@ fn write_nonprint_to_end<W: Write>(in_buf: &[u8], writer: &mut W, tab: &[u8]) ->
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
match byte {
|
match byte {
|
||||||
9 => writer.write_all(tab),
|
9 => writer.write_all(tab),
|
||||||
0...8 | 10...31 => writer.write_all(&['^' as u8, byte + 64]),
|
0...8 | 10...31 => writer.write_all(&['^' as u8, byte + 64]),
|
||||||
32...126 => writer.write_all(&[byte]),
|
32...126 => writer.write_all(&[byte]),
|
||||||
127 => writer.write_all(&['^' as u8, byte - 64]),
|
127 => writer.write_all(&['^' as u8, byte - 64]),
|
||||||
128...159 => writer.write_all(&['M' as u8, '-' as u8, '^' as u8, byte - 64]),
|
128...159 => writer.write_all(&['M' as u8, '-' as u8, '^' as u8, byte - 64]),
|
||||||
160...254 => writer.write_all(&['M' as u8, '-' as u8, byte - 128]),
|
160...254 => writer.write_all(&['M' as u8, '-' as u8, byte - 128]),
|
||||||
_ => writer.write_all(&['M' as u8, '-' as u8, '^' as u8, 63]),
|
_ => writer.write_all(&['M' as u8, '-' as u8, '^' as u8, 63]),
|
||||||
}
|
}.unwrap();
|
||||||
.unwrap();
|
|
||||||
count += 1;
|
count += 1;
|
||||||
}
|
}
|
||||||
if count != in_buf.len() { count + 1 } else { 0 }
|
if count != in_buf.len() { count + 1 } else { 0 }
|
||||||
|
|
Loading…
Reference in a new issue