From: Ben Gras Date: Tue, 10 Dec 2013 19:04:02 +0000 (+0100) Subject: X-Git-Tag: v3.3.0~459 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/man.dnssec-checkds.html?a=commitdiff_plain;h=09fab4dc045239b306217f047ce7baa8087a3d12;p=minix.git Change-Id: I237e141e2a6409c7100db4adb14a90fbb46294b4 --- diff --git a/sys/sys/ttydefaults.h b/sys/sys/ttydefaults.h index 627da0712..1c3687374 100644 --- a/sys/sys/ttydefaults.h +++ b/sys/sys/ttydefaults.h @@ -45,14 +45,14 @@ /* * Defaults on "first" open. */ -#define TTYDEF_IFLAG (BRKINT | ICRNL | IXON | IXANY) -#define TTYDEF_OFLAG (OPOST | ONLCR ) -#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE) +#define TTYDEF_IFLAG (BRKINT | ICRNL | IMAXBEL | IXON | IXANY) +#define TTYDEF_OFLAG (OPOST | ONLCR | OXTABS) +#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) #define TTYDEF_CFLAG (CREAD | CS8 | HUPCL) #ifdef __minix -#define TTYDEF_SPEED (B115200) +#define TTYDEF_SPEED (B115200) #else -#define TTYDEF_SPEED (B9600) +#define TTYDEF_SPEED (B9600) #endif /* @@ -60,8 +60,8 @@ */ #define CTRL(x) (x&037) #define CEOF CTRL('d') -#define CEOL _POSIX_VDISABLE -#define CERASE CTRL('h') +#define CEOL ((unsigned char)'\377') /* XXX avoid _POSIX_VDISABLE */ +#define CERASE 0177 #define CINTR CTRL('c') #define CSTATUS CTRL('t') #define CKILL CTRL('u') @@ -82,4 +82,38 @@ #define CRPRNT CREPRINT #define CFLUSH CDISCARD -#endif /* _SYS_TTYDEFAULTS_H_ */ +/* PROTECTED INCLUSION ENDS HERE */ +#endif /* !_SYS_TTYDEFAULTS_H_ */ + +/* + * #define TTYDEFCHARS to include an array of default control characters. + */ +#ifdef _KERNEL +#ifdef TTYDEFCHARS +const cc_t ttydefchars[NCCS] = { + [VEOF] = CEOF, + [VEOL] = CEOL, + [VEOL2] = CEOL, + [VERASE] = CERASE, + [VWERASE] = CWERASE, + [VKILL] = CKILL, + [VREPRINT] = CREPRINT, + [7] = _POSIX_VDISABLE, /* spare */ + [VINTR] = CINTR, + [VQUIT] = CQUIT, + [VSUSP] = CSUSP, + [VDSUSP] = CDSUSP, + [VSTART] = CSTART, + [VSTOP] = CSTOP, + [VLNEXT] = CLNEXT, + [VDISCARD] = CDISCARD, + [VMIN] = CMIN, + [VTIME] = CTIME, + [VSTATUS] = CSTATUS, + [19] = _POSIX_VDISABLE, /* spare */ +}; +#undef TTYDEFCHARS +#else +extern const cc_t ttydefchars[NCCS]; +#endif +#endif /* _KERNEL */