aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--loginutils/getty.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/loginutils/getty.c b/loginutils/getty.c
index 4b1b73bef..174542841 100644
--- a/loginutils/getty.c
+++ b/loginutils/getty.c
@@ -334,18 +334,19 @@ static void finalize_tty_attrs(void)
334 * observed to improve backspacing through Unicode chars 334 * observed to improve backspacing through Unicode chars
335 */ 335 */
336 336
337 /* line buffered input (NL or EOL or EOF chars end a line); 337 /* ICANON line buffered input (NL or EOL or EOF chars end a line);
338 * recognize INT/QUIT/SUSP chars; 338 * ISIG recognize INT/QUIT/SUSP chars;
339 * echo input chars; 339 * ECHO echo input chars;
340 * echo BS-SP-BS on erase character; 340 * ECHOE echo BS-SP-BS on erase character;
341 * echo kill char specially, not as ^c (ECHOKE controls how exactly); 341 * ECHOK echo kill char specially, not as ^c (ECHOKE controls how exactly);
342 * erase all input via BS-SP-BS on kill char (else go to next line) 342 * ECHOKE erase all input via BS-SP-BS on kill char (else go to next line)
343 * ECHOCTL Echo ctrl chars as ^c (else echo verbatim:
344 * e.g. up arrow emits "ESC-something" and thus moves cursor up!)
343 */ 345 */
344 G.tty_attrs.c_lflag |= ICANON | ISIG | ECHO | ECHOE | ECHOK | ECHOKE; 346 G.tty_attrs.c_lflag |= ICANON | ISIG | ECHO | ECHOE | ECHOK | ECHOKE | ECHOCTL;
345 /* Other bits in c_lflag: 347 /* Other bits in c_lflag:
346 * XCASE Map uppercase to \lowercase [tried, doesn't work] 348 * XCASE Map uppercase to \lowercase [tried, doesn't work]
347 * ECHONL Echo NL even if ECHO is not set 349 * ECHONL Echo NL even if ECHO is not set
348 * ECHOCTL Echo ctrl chars as ^c (else don't echo) - maybe set this?
349 * ECHOPRT On erase, echo erased chars 350 * ECHOPRT On erase, echo erased chars
350 * [qwe<BS><BS><BS> input looks like "qwe\ewq/" on screen] 351 * [qwe<BS><BS><BS> input looks like "qwe\ewq/" on screen]
351 * NOFLSH Don't flush input buffer after interrupt or quit chars 352 * NOFLSH Don't flush input buffer after interrupt or quit chars