1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-09 09:27:59 +00:00

Now that we can configure whether ^C and friends generate Telnet IP

and friends, we should honour the user's choice even in line editing
mode. In particular, Telnet talkers don't like us randomly spraying
Telnet IP whenever the user accidentally hits ^C, so this is not a
helpful default.

[originally from svn r1316]
This commit is contained in:
Simon Tatham 2001-10-24 11:50:07 +00:00
parent aa5f38e53c
commit 830c1ea580

View File

@ -132,6 +132,13 @@ void ldisc_send(char *buf, int len, int interactive)
term_buflen--;
}
back->special(TS_EL);
/*
* We don't send IP, SUSP or ABORT if the user has
* configured telnet specials off! This breaks
* talkers otherwise.
*/
if (!cfg.telnet_keyboard)
goto default_case;
if (c == CTRL('C'))
back->special(TS_IP);
if (c == CTRL('Z'))
@ -204,6 +211,7 @@ void ldisc_send(char *buf, int len, int interactive)
}
/* FALLTHROUGH */
default: /* get to this label from ^V handler */
default_case:
if (term_buflen >= term_bufsiz) {
term_bufsiz = term_buflen + 256;
term_buf = saferealloc(term_buf, term_bufsiz);