mirror of
https://github.com/tio/tio.git
synced 2026-05-01 14:57:59 +02:00
Ignore newlines in hex output
This commit is contained in:
parent
4b928a54b2
commit
858b898bbb
1 changed files with 1 additions and 8 deletions
|
|
@ -29,14 +29,7 @@ char ansi_format[30];
|
||||||
|
|
||||||
void print_hex(char c)
|
void print_hex(char c)
|
||||||
{
|
{
|
||||||
if ((c == '\n') || (c == '\r'))
|
printf("%02x ", (unsigned char) c);
|
||||||
{
|
|
||||||
printf("%c", c);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
printf("%02x ", (unsigned char) c);
|
|
||||||
}
|
|
||||||
|
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue