Print warnings when IUTF8 missing

This commit is contained in:
Keith Winstein
2012-03-31 15:20:30 -04:00
parent 9119fa1c7d
commit 9a7f3ad33d
4 changed files with 17 additions and 1 deletions
+4 -1
View File
@@ -62,11 +62,14 @@ void STMClient::init( void )
/* Put terminal driver in raw mode */
raw_termios = saved_termios;
#ifdef HAVE_IUTF8
if ( !(raw_termios.c_iflag & IUTF8) ) {
/* SSH should also convey IUTF8 across connection. */
// fprintf( stderr, "Warning: Locale is UTF-8 but termios IUTF8 flag not set. Setting IUTF8 flag.\n" );
/* Probably not really necessary since we are putting terminal driver into raw mode anyway. */
raw_termios.c_iflag |= IUTF8;
}
#endif /* HAVE_IUTF8 */
cfmakeraw( &raw_termios );