edit: set edchars manually on OS/2

OS/2 kLIBC have termio.h and termios.h. But the real functions are
dummies.

Now Ctrl-C and Ctrl-D work well.

    modified:   edit.c
This commit is contained in:
KO Myung-Hun 2015-07-07 08:28:55 +09:00
parent 01648d4495
commit edc36cce7f
1 changed files with 13 additions and 0 deletions

13
edit.c
View File

@ -3340,6 +3340,19 @@ x_mode(bool onoff)
edchars.werase = tty_state.c_cc[VWERASE];
#endif
#ifdef __OS2__
if (edchars.erase == 0)
edchars.erase = 8;
if (edchars.kill == 0)
edchars.kill = 21;
if (edchars.intr == 0)
edchars.intr = 3;
if (edchars.quit == 0)
edchars.quit = 28;
if (edchars.eof == 0)
edchars.eof = 4;
#endif
#ifdef _POSIX_VDISABLE
/* Convert unset values to internal 'unset' value */
if (edchars.erase == _POSIX_VDISABLE)