mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2024-11-16 15:44:04 +01:00
Implement meta bit in more cosher way after contacting with zmbenhal
Shut up compiler warning
This commit is contained in:
parent
65bbec73d7
commit
8ea50e34cb
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=3508
@ -143,6 +143,12 @@ int ch;
|
||||
ch = fifo_pull();
|
||||
}
|
||||
|
||||
/* This should be eliminated */
|
||||
/* handle 8-bit input */
|
||||
if (ch & 0x80)
|
||||
if (!win->_use_meta)
|
||||
ch &= 0x7f;
|
||||
|
||||
/* there must be a simpler way of doing this */
|
||||
if (!(win->_flags & _ISPAD) &&
|
||||
SP->_echo && ch < 0400) { /* ch < 0400 => not a keypad key */
|
||||
|
@ -49,6 +49,7 @@ int stolen, topstolen;
|
||||
extern char _ncurses_copyright[];
|
||||
char *use_it = _ncurses_copyright;
|
||||
|
||||
use_it = use_it; /* shut up compiler */
|
||||
#ifdef TRACE
|
||||
_init_trace();
|
||||
T(("newterm(%s,%x,%x) called", term, ofp, ifp));
|
||||
|
@ -149,7 +149,12 @@ WINDOW *win;
|
||||
win->_scroll = FALSE;
|
||||
win->_leave = FALSE;
|
||||
win->_use_keypad = FALSE;
|
||||
#ifdef TERMIOS
|
||||
win->_use_meta = ((cur_term->Ottyb.c_cflag & CSIZE) == CS8 &&
|
||||
!(cur_term->Ottyb.c_iflag & ISTRIP));
|
||||
#else
|
||||
win->_use_meta = FALSE;
|
||||
#endif
|
||||
win->_delay = -1;
|
||||
win->_immed = FALSE;
|
||||
win->_sync = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user