mirror of
https://github.com/tio/tio.git
synced 2026-05-01 23:07:58 +02:00
Fixed tio_printf macro
This commit is contained in:
parent
065ee51291
commit
fa079c6852
1 changed files with 4 additions and 5 deletions
|
|
@ -47,10 +47,11 @@ static bool tainted = false;
|
||||||
static int fd;
|
static int fd;
|
||||||
|
|
||||||
#define tio_printf(format, args...) \
|
#define tio_printf(format, args...) \
|
||||||
|
{ \
|
||||||
if (tainted) putchar('\n'); \
|
if (tainted) putchar('\n'); \
|
||||||
color_printf("[tio %s] " format, current_time(), ## args); \
|
color_printf("[tio %s] " format, current_time(), ## args); \
|
||||||
tainted = false;
|
tainted = false; \
|
||||||
|
}
|
||||||
|
|
||||||
void handle_command_sequence(char input_char, char previous_char, char *output_char, bool *forward)
|
void handle_command_sequence(char input_char, char previous_char, char *output_char, bool *forward)
|
||||||
{
|
{
|
||||||
|
|
@ -88,9 +89,7 @@ void handle_command_sequence(char input_char, char previous_char, char *output_c
|
||||||
tio_printf(" Parity: %s", option.parity);
|
tio_printf(" Parity: %s", option.parity);
|
||||||
tio_printf(" Output delay: %d", option.output_delay);
|
tio_printf(" Output delay: %d", option.output_delay);
|
||||||
if (option.log)
|
if (option.log)
|
||||||
{
|
|
||||||
tio_printf(" Log file: %s", option.log_filename);
|
tio_printf(" Log file: %s", option.log_filename);
|
||||||
}
|
|
||||||
*forward = false;
|
*forward = false;
|
||||||
break;
|
break;
|
||||||
case KEY_Q:
|
case KEY_Q:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue