diff --git a/NEWS b/NEWS index 848937e2a..62afa4a2a 100644 --- a/NEWS +++ b/NEWS @@ -80,6 +80,8 @@ Miscellaneous: reloaded. See elinks-users mail from 28 Oct 2005. * several accesskey fixes * in Lua: don't write to the string returned by lua_tostring +* minor bug 54, Debian bug 338402: don't force the terminal to 8 bits + with no parity * minor bug 972: preserve the background color and underlining in spaces when justifying * minor bug 284: render closing bracket for HTML element SUB in the diff --git a/configure.in b/configure.in index 7be3a9655..1740106e5 100644 --- a/configure.in +++ b/configure.in @@ -290,7 +290,7 @@ AC_PROG_GCC_TRADITIONAL AC_FUNC_MEMCMP AC_FUNC_MMAP AC_FUNC_STRFTIME -AC_CHECK_FUNCS(atoll cfmakeraw gethostbyaddr herror strerror) +AC_CHECK_FUNCS(atoll gethostbyaddr herror strerror) AC_CHECK_FUNCS(popen uname access chmod alarm timegm mremap) AC_CHECK_FUNCS(strcasecmp strncasecmp strcasestr strstr strchr strrchr) AC_CHECK_FUNCS(memmove bcopy stpcpy strdup index isdigit mempcpy memrchr) diff --git a/src/osdep/osdep.c b/src/osdep/osdep.c index d7705bed9..b4ea29635 100644 --- a/src/osdep/osdep.c +++ b/src/osdep/osdep.c @@ -805,20 +805,16 @@ unblock_stdin(void) void elinks_cfmakeraw(struct termios *t) { -#ifdef HAVE_CFMAKERAW - cfmakeraw(t); -#ifdef VMIN - t->c_cc[VMIN] = 1; /* cfmakeraw() is broken on AIX --mikulas */ -#endif -#else + /* Bug 54: Do not alter the character-size and parity bits in + * t->c_cflag. If they have unusual values, the terminal + * probably requires those and won't work if ELinks changes + * the flags. The cfmakeraw function would set 8-bit characters + * and no parity, so don't use that. */ t->c_iflag &= ~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON); t->c_oflag &= ~OPOST; t->c_lflag &= ~(ECHO|ECHONL|ICANON|ISIG|IEXTEN); - t->c_cflag &= ~(CSIZE|PARENB); - t->c_cflag |= CS8; t->c_cc[VMIN] = 1; t->c_cc[VTIME] = 0; -#endif } #if !defined(CONFIG_MOUSE) || (!defined(CONFIG_GPM) && !defined(CONFIG_SYSMOUSE) && !defined(OS2_MOUSE))