X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/putty/blobdiff_plain/4a693cfc5c3ee0e639bbee0215345e921715ab04..193c8d4a7559f40fe0e0c8610cf6832a0e976e77:/telnet.c diff --git a/telnet.c b/telnet.c index 05c9bf64..dc98a727 100644 --- a/telnet.c +++ b/telnet.c @@ -426,7 +426,7 @@ static void process_subneg(Telnet telnet) logevent(telnet->frontend, logbuf); sfree(logbuf); if (telnet->sb_opt == TELOPT_OLD_ENVIRON) { - if (conf_get_str(telnet->conf, CONF_rfc_environ)) { + if (conf_get_int(telnet->conf, CONF_rfc_environ)) { value = RFC_VALUE; var = RFC_VAR; } else { @@ -667,6 +667,12 @@ static int telnet_closing(Plug plug, const char *error_msg, int error_code, { Telnet telnet = (Telnet) plug; + /* + * We don't implement independent EOF in each direction for Telnet + * connections; as soon as we get word that the remote side has + * sent us EOF, we wind up the whole connection. + */ + if (telnet->s) { sk_close(telnet->s); telnet->s = NULL;