[13057] in Athena Bugs
telnetd won't set terminal speed >9600 even if asked
daemon@ATHENA.MIT.EDU (brlewis@MIT.EDU)
Thu Dec 29 13:51:39 1994
From: brlewis@MIT.EDU
Date: Thu, 29 Dec 94 13:51:34 -0500
To: bugs@MIT.EDU
Apparently some systems don't define B19200 or B38400, so the BSD
telnetd sort of maxed out at 9600. I'm including a patch that will do
19.2 or 38.4 if defined, otherwise do 9600.
This was the only difference between Ultrix telnetd and the new telnetd
that shows up with stty everything. Gotta keep looking for solutions to
that zmodem problem.
*** /tmp/,RCSt1a17455 Thu Dec 29 13:43:51 1994
--- sys_term.c Wed Dec 28 10:51:20 1994
***************
*** 950,955 ****
--- 950,961 ----
/*
* A table of available terminal speeds
*/
+ #ifndef B19200
+ #define B19200 B9600
+ #endif
+ #ifndef B38400
+ #define B38400 B9600
+ #endif
struct termspeeds {
int speed;
int value;
***************
*** 958,965 ****
{ 110, B110 }, { 134, B134 }, { 150, B150 },
{ 200, B200 }, { 300, B300 }, { 600, B600 },
{ 1200, B1200 }, { 1800, B1800 }, { 2400, B2400 },
! { 4800, B4800 }, { 9600, B9600 }, { 19200, B9600 },
! { 38400, B9600 }, { -1, B9600 }
};
void
--- 964,971 ----
{ 110, B110 }, { 134, B134 }, { 150, B150 },
{ 200, B200 }, { 300, B300 }, { 600, B600 },
{ 1200, B1200 }, { 1800, B1800 }, { 2400, B2400 },
! { 4800, B4800 }, { 9600, B9600 }, { 19200, B19200 },
! { 38400, B38400 }, { -1, B38400 }
};
void
***************
*** 1135,1142 ****
termbuf.c_iflag |= ICRNL;
termbuf.c_iflag &= ~IXOFF;
# endif /* defined(USE_TERMIO) && !defined(CRAY) && (BSD <= 43) */
! tty_rspeed((def_rspeed > 0) ? def_rspeed : 9600);
! tty_tspeed((def_tspeed > 0) ? def_tspeed : 9600);
# ifdef LINEMODE
if (waslm)
tty_setlinemode(1);
--- 1141,1148 ----
termbuf.c_iflag |= ICRNL;
termbuf.c_iflag &= ~IXOFF;
# endif /* defined(USE_TERMIO) && !defined(CRAY) && (BSD <= 43) */
! tty_rspeed((def_rspeed > 0) ? def_rspeed : 38400);
! tty_tspeed((def_tspeed > 0) ? def_tspeed : 38400);
# ifdef LINEMODE
if (waslm)
tty_setlinemode(1);