tchars
struct termios tchars;
(void)tcgetattr(SHIN, &tchars);
tchars.c_cc[VEOL] = ESC;
if (tchars.c_lflag & ICANON)
tchars.c_lflag |= ICANON;
tchars.c_cc[VEOL] = _POSIX_VDISABLE;
(void)tcsetattr(SHIN, on, &tchars);
edchars.intr = cb.tchars.t_intrc;
edchars.quit = cb.tchars.t_quitc;
edchars.eof = cb.tchars.t_eofc;
cb.tchars.t_intrc = -1;
cb.tchars.t_quitc = -1;
if (ioctl(fd, TIOCGETC, &ts->tchars) < 0)
if (ioctl(fd, TIOCSETC, &ts->tchars) < 0)
struct tchars tchars;
struct tchars *tc = (struct tchars *)data;
struct tchars *tc = (struct tchars *)data;
#define TIOCSETC _IOW('t',17,struct tchars)/* set special characters */
#define TIOCGETC _IOR('t',18,struct tchars)/* get special characters */