TMXR: Make sure to send the telnet mantra on outgoing telnet connects

This commit is contained in:
Mark Pizzolato 2018-09-06 02:07:37 -07:00
parent 6f1a01d6fa
commit 99cabebbf0

View file

@ -1203,6 +1203,12 @@ for (i = 0; i < mp->lines; i++) { /* check each line in se
tmxr_debug_connect_line (lp, msg); tmxr_debug_connect_line (lp, msg);
free (sockname); free (sockname);
free (peername); free (peername);
if (!lp->notelnet) {
sim_write_sock (newsock, (char *)mantra, sizeof(mantra));
tmxr_debug (TMXR_DBG_XMT, lp, "Sending", (char *)mantra, sizeof(mantra));
lp->telnet_sent_opts = (uint8 *)realloc (lp->telnet_sent_opts, 256);
memset (lp->telnet_sent_opts, 0, 256);
}
return i; return i;
case -1: /* failed connection */ case -1: /* failed connection */
sprintf (msg, "tmxr_poll_conn() - Outgoing Line Connection to %s failed", lp->destination); sprintf (msg, "tmxr_poll_conn() - Outgoing Line Connection to %s failed", lp->destination);