fixed tty_print_anychar, replaced addch to addstr when MC build with ncurses library.

Signed-off-by: Ilia Maslakov <il.smind@google.com>
This commit is contained in:
Ilia Maslakov 2009-10-13 07:08:00 +00:00
parent 080b639d47
commit db419a27c1

View File

@ -308,18 +308,14 @@ tty_print_anychar (int c)
{
unsigned char str[6 + 1];
if (c > 255) {
int res = g_unichar_to_utf8 (c, (char *) str);
if (res == 0) {
str[0] = '.';
str[1] = '\0';
} else {
str[res] = '\0';
}
addstr (str_term_form ((char *) str));
int res = g_unichar_to_utf8 (c, (char *) str);
if (res == 0) {
str[0] = '.';
str[1] = '\0';
} else {
addch (c);
str[res] = '\0';
}
addstr (str_term_form ((char *) str));
}
void