From 05b6a554d39ee63a8bde9cc4cefdfe2edcdaf23e Mon Sep 17 00:00:00 2001 From: Jakub Wilk Date: Sat, 7 May 2016 20:57:30 +0200 Subject: [PATCH] Completed the ^g to ^t transition In 72a287f18995 the escape key was changed from ^g to ^t, but some code and comments still referred to the old key. --- src/tty.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/tty.c b/src/tty.c index c3b7314..2e298c6 100644 --- a/src/tty.c +++ b/src/tty.c @@ -73,7 +73,7 @@ void wait_for_tty_device(void) /* Read one character */ n = read(STDIN_FILENO, &c_stdin[0], 1); - /* Exit upon ctrl-g + q sequence */ + /* Exit upon ctrl-t + q sequence */ c_stdin[2] = c_stdin[1]; c_stdin[1] = c_stdin[0]; if ((c_stdin[1] == KEY_Q) && (c_stdin[2] == KEY_CTRL_T)) @@ -210,7 +210,7 @@ int connect_tty(void) if (option.log) log_write(c_tty); - if (c_tty != 0x7) // Small trick to avoid ctrl-g echo + if (c_tty != KEY_CTRL_T) // Small trick to avoid ctrl-t echo tainted = true; } else { @@ -226,7 +226,7 @@ int connect_tty(void) if ((c_stdin[0] != KEY_Q) && (c_stdin[0] != KEY_CTRL_T)) tainted = true; - /* Exit upon ctrl-g + q sequence */ + /* Exit upon ctrl-t + q sequence */ c_stdin[2] = c_stdin[1]; c_stdin[1] = c_stdin[0]; if ((c_stdin[1] == KEY_Q) && (c_stdin[2] == KEY_CTRL_T))